4 #include <linux/cdev.h>
5 #include <linux/list.h>
6 #include <linux/sched.h>
7 #include <linux/slab.h>
10 /* Global Control IOCTLs */
11 #define V3_START_GUEST 10
12 #define V3_STOP_GUEST 11
13 #define V3_CREATE_GUEST 12
14 #define V3_FREE_GUEST 13
16 #define V3_ADD_MEMORY 50
18 /* VM Specific IOCTLs */
19 #define V3_VM_CONSOLE_CONNECT 20
22 #define V3_VM_PAUSE 23
23 #define V3_VM_CONTINUE 24
25 #define V3_VM_LAUNCH 25
30 #define V3_VM_INSPECT 30
32 #define V3_VM_MOVE_CORE 33
34 #define V3_VM_FB_INPUT (256+1)
35 #define V3_VM_FB_QUERY (256+2)
37 #define V3_VM_HOST_DEV_CONNECT (10244+1)
39 #define V3_VM_KSTREAM_USER_CONNECT (11244+1)
43 unsigned long long size;
46 } __attribute__((packed));
48 struct v3_mem_region {
49 unsigned long long base_addr;
50 unsigned long long num_pages;
51 } __attribute__((packed));
53 struct v3_core_move_cmd{
54 unsigned short vcore_id;
55 unsigned short pcore_id;
56 } __attribute__((packed));
58 struct v3_chkpt_info {
60 char url[256]; /* This might need to be bigger... */
61 } __attribute__((packed));
65 void * trace_malloc(size_t size, gfp_t flags);
66 void trace_free(const void * objp);
78 struct rb_root vm_ctrls;
79 struct list_head exts;
85 // For now MAX_VMS must be a multiple of 8
86 // This is due to the minor number bitmap
91 int palacios_vmm_init( void );
92 int palacios_vmm_exit( void );