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 queue implementation
[palacios.git] / palacios / include / palacios / vmm_queue.h
1 #ifndef __VMM_QUEUE_H__
2 #define __VMM_QUEUE_H__
3
4 #ifdef __V3VEE__
5
6 #include <palacios/vmm.h>
7 #include <palacios/vmm_list.h>
8
9
10
11 /* IMPORTANT:
12  * This implementation currently does no locking, and as such is not 
13  * SMP/thread/interrupt safe
14  */
15
16
17 struct queue_entry {
18   addr_t entry;
19   struct list_head entry_list;
20 };
21
22
23 struct gen_queue {
24   uint_t num_entries;
25   struct list_head entries;
26
27   // We really need to implement this....
28   // void * lock;
29 };
30
31
32 struct gen_queue * create_queue();
33 void init_queue(struct gen_queue * queue);
34
35 void enqueue(struct gen_queue * queue, addr_t entry);
36 addr_t dequeue(struct gen_queue * queue);
37
38
39
40 #endif // ! __V3VEE__
41
42 #endif