Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


more extension ports
[palacios.git] / linux_module / palacios.h
1 #ifndef _PALACIOS_H
2 #define _PALACIOS_H
3
4 #include <linux/cdev.h>
5 #include <linux/list.h>
6 #include <linux/sched.h>
7 #include <linux/slab.h>
8
9
10
11
12 #ifdef V3_CONFIG_HOST_DEVICE
13 #include "palacios-host-dev.h"
14 #endif
15
16
17 /* Global Control IOCTLs */
18 #define V3_START_GUEST 10
19 #define V3_ADD_MEMORY 50
20 #define V3_START_NETWORK 60
21
22 /* VM Specific IOCTLs */
23 #define V3_VM_CONSOLE_CONNECT 20
24 #define V3_VM_STREAM_CONNECT 21
25 #define V3_VM_STOP 22
26
27 #define V3_VM_INSPECT 30
28
29 #define V3_VM_FB_INPUT (256+1)
30 #define V3_VM_FB_QUERY (256+2)
31
32 #define V3_VM_HOST_DEV_CONNECT (10244+1)
33
34
35 struct v3_guest_img {
36     unsigned long long size;
37     void * guest_data;
38     char name[128];
39 };
40
41 struct v3_mem_region {
42     unsigned long long base_addr;
43     unsigned long long num_pages;
44 };
45
46
47 void * trace_malloc(size_t size, gfp_t flags);
48 void trace_free(const void * objp);
49
50
51 struct v3_guest {
52     void * v3_ctx;
53
54     void * img; 
55     u32 img_size;
56
57     char name[128];
58
59
60     struct rb_root vm_ctrls;
61     struct list_head exts;
62
63
64 #ifdef V3_CONFIG_HOST_DEVICE
65     struct palacios_host_dev hostdev;
66 #endif
67
68
69     struct completion start_done;
70     struct completion thread_done;
71
72     dev_t vm_dev; 
73     struct cdev cdev;
74 };
75
76 // For now MAX_VMS must be a multiple of 8
77 // This is due to the minor number bitmap
78 #define MAX_VMS 32
79
80
81
82
83
84 extern void send_key_to_palacios(unsigned char status, unsigned char scan_code);
85
86
87 int palacios_vmm_init( void );
88 int palacios_vmm_exit( void );
89
90
91
92 #endif