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.


added inspection framework
[palacios.git] / palacios / include / palacios / vmm_inspector.h
1 /* 
2  * This file is part of the Palacios Virtual Machine Monitor developed
3  * by the V3VEE Project with funding from the United States National 
4  * Science Foundation and the Department of Energy.  
5  *
6  * The V3VEE Project is a joint project between Northwestern University
7  * and the University of New Mexico.  You can find out more at 
8  * http://www.v3vee.org
9  *
10  * Copyright (c) 2008, Jack Lange <jarusl@cs.northwestern.edu> 
11  * Copyright (c) 2008, The V3VEE Project <http://www.v3vee.org> 
12  * All rights reserved.
13  *
14  * Author: Jack Lange <jarusl@cs.northwestern.edu>
15  *
16  * This is free software.  You are permitted to use,
17  * redistribute, and modify it as specified in the file "V3VEE_LICENSE".
18  */
19
20
21 #ifndef __VMM_INSPECTOR_H__
22 #define __VMM_INSPECTOR_H__
23
24
25 typedef void v3_inspect_node_t;
26
27 #ifdef __V3VEE__
28
29 #include <palacios/vmm_multitree.h>
30
31
32
33 // Flags
34 #define SERIALIZABLE 1
35 #define READ_ONLY 2
36 #define HOOKED 4
37
38 struct v3_inspector_state {
39     struct v3_mtree state_tree;
40
41 };
42
43
44
45 int v3_init_inspector(struct v3_vm_info * vm);
46 int v3_init_inspector_core(struct guest_info * core);
47
48
49 int v3_inspect_8(v3_inspect_node_t * node, char * name, uint8_t * val);
50 int v3_inspect_16(v3_inspect_node_t * node, char * name, uint16_t * val);
51 int v3_inspect_32(v3_inspect_node_t * node, char * name, uint32_t * val);
52 int v3_inspect_64(v3_inspect_node_t * node, char * name, uint64_t * val);
53 int v3_inspect_addr(v3_inspect_node_t * node, char * name, addr_t * val);
54 int v3_inspect_buf(v3_inspect_node_t * node, char * name, uint8_t * buf, uint64_t size);
55
56 v3_inspect_node_t * v3_inspect_add_subtree(v3_inspect_node_t * root, char * name);
57
58
59
60
61
62 #endif
63
64
65 struct v3_inspection_value {
66     char * name;
67     unsigned char * value;
68     unsigned long long size;
69     unsigned char flags;
70 };
71
72
73
74
75 int v3_get_inspection_value(v3_inspect_node_t * node, char * name, 
76                             struct v3_inspection_value * value);
77
78 v3_inspect_node_t * v3_get_inspection_root(struct v3_vm_info * vm);
79 v3_inspect_node_t * v3_get_inspection_subtree(v3_inspect_node_t * root, char * name);
80 v3_inspect_node_t * v3_inspection_node_next(v3_inspect_node_t * node);
81
82 #endif