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.


Initial integration and reimplementation of user-space interface for keyed streams
[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 /* Global Control IOCTLs */
11 #define V3_START_GUEST 10
12 #define V3_ADD_MEMORY 50
13
14 /* VM Specific IOCTLs */
15 #define V3_VM_CONSOLE_CONNECT 20
16
17 #define V3_VM_STOP 22
18
19 #define V3_VM_INSPECT 30
20
21 #define V3_VM_FB_INPUT (256+1)
22 #define V3_VM_FB_QUERY (256+2)
23
24 #define V3_VM_HOST_DEV_CONNECT (10244+1)
25
26 #define V3_VM_KSTREAM_USER_CONNECT (11244+1)
27
28
29 struct v3_guest_img {
30     unsigned long long size;
31     void * guest_data;
32     char name[128];
33 };
34
35 struct v3_mem_region {
36     unsigned long long base_addr;
37     unsigned long long num_pages;
38 };
39
40
41 void * trace_malloc(size_t size, gfp_t flags);
42 void trace_free(const void * objp);
43
44
45 struct v3_guest {
46     void * v3_ctx;
47
48     void * img; 
49     u32 img_size;
50
51     char name[128];
52
53
54     struct rb_root vm_ctrls;
55     struct list_head exts;
56
57     struct completion start_done;
58     struct completion thread_done;
59
60     dev_t vm_dev; 
61     struct cdev cdev;
62 };
63
64 // For now MAX_VMS must be a multiple of 8
65 // This is due to the minor number bitmap
66 #define MAX_VMS 32
67
68
69
70 int palacios_vmm_init( void );
71 int palacios_vmm_exit( void );
72
73
74
75 #endif