4 #include <linux/cdev.h>
5 #include <linux/list.h>
6 #include <linux/sched.h>
7 #include <linux/slab.h>
10 #ifdef V3_CONFIG_GRAPHICS_CONSOLE
11 #include "palacios-graphics-console.h"
14 #ifdef V3_CONFIG_HOST_DEVICE
15 #include "palacios-host-dev.h"
19 /* Global Control IOCTLs */
20 #define V3_START_GUEST 10
21 #define V3_ADD_MEMORY 50
22 #define V3_START_NETWORK 60
24 /* VM Specific IOCTLs */
25 #define V3_VM_CONSOLE_CONNECT 20
26 #define V3_VM_STREAM_CONNECT 21
29 #define V3_VM_INSPECT 30
31 #define V3_VM_FB_INPUT (256+1)
32 #define V3_VM_FB_QUERY (256+2)
34 #define V3_VM_HOST_DEV_CONNECT (10244+1)
38 unsigned long long size;
43 struct v3_mem_region {
44 unsigned long long base_addr;
45 unsigned long long num_pages;
49 void * trace_malloc(size_t size, gfp_t flags);
50 void trace_free(const void * objp);
62 struct rb_root vm_ctrls;
63 struct list_head exts;
66 #ifdef V3_CONFIG_GRAPHICS_CONSOLE
67 struct palacios_graphics_console graphics_console;
70 #ifdef V3_CONFIG_HOST_DEVICE
71 struct palacios_host_dev hostdev;
75 struct completion start_done;
76 struct completion thread_done;
82 // For now MAX_VMS must be a multiple of 8
83 // This is due to the minor number bitmap
90 extern void send_key_to_palacios(unsigned char status, unsigned char scan_code);
93 int palacios_vmm_init( void );
94 int palacios_vmm_exit( void );