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.


fixed all the printf style warnings/errors
[palacios.git] / palacios / src / palacios / vmm_intr.c
index 84a645b..87fbcdb 100644 (file)
 
 
 
-void init_interrupt_state(struct guest_info * info) {
+void v3_init_interrupt_state(struct guest_info * info) {
   info->intr_state.excp_pending = 0;
   info->intr_state.excp_num = 0;
   info->intr_state.excp_error_code = 0;
 
   memset((uchar_t *)(info->intr_state.hooks), 0, sizeof(struct v3_irq_hook *) * 256);
-
-  info->vm_ops.raise_irq = &v3_raise_irq;
-  info->vm_ops.lower_irq = &v3_lower_irq; 
 }
 
-void set_intr_controller(struct guest_info * info, struct intr_ctrl_ops * ops, void * state) {
+void v3_set_intr_controller(struct guest_info * info, struct intr_ctrl_ops * ops, void * state) {
   info->intr_state.controller = ops;
   info->intr_state.controller_state = state;
 }
@@ -105,10 +102,10 @@ int v3_hook_passthrough_irq(struct guest_info * info, uint_t irq)
                       NULL);
 
   if (rc) { 
-    PrintError("guest_irq_injection: failed to hook irq 0x%x (guest=0x%x)\n", irq, info);
+    PrintError("guest_irq_injection: failed to hook irq 0x%x (guest=0x%p)\n", irq, (void *)info);
     return -1;
   } else {
-    PrintDebug("guest_irq_injection: hooked irq 0x%x (guest=0x%x)\n", irq, info);
+    PrintDebug("guest_irq_injection: hooked irq 0x%x (guest=0x%p)\n", irq, (void *)info);
     return 0;
   }
 }
@@ -209,9 +206,9 @@ int v3_raise_irq(struct guest_info * info, int irq) {
   return 0;
 }
 
 
-int intr_pending(struct guest_info * info) {
+
+int v3_intr_pending(struct guest_info * info) {
   struct v3_intr_state * intr_state = &(info->intr_state);
 
   //  PrintDebug("[intr_pending]\n");
@@ -227,7 +224,7 @@ int intr_pending(struct guest_info * info) {
 }
 
 
-uint_t get_intr_number(struct guest_info * info) {
+uint_t v3_get_intr_number(struct guest_info * info) {
   struct v3_intr_state * intr_state = &(info->intr_state);
 
   if (intr_state->excp_pending == 1) {
@@ -243,7 +240,7 @@ uint_t get_intr_number(struct guest_info * info) {
 }
 
 
-intr_type_t get_intr_type(struct guest_info * info) {
+intr_type_t v3_get_intr_type(struct guest_info * info) {
   struct v3_intr_state * intr_state = &(info->intr_state);
 
   if (intr_state->excp_pending) {
@@ -262,7 +259,7 @@ intr_type_t get_intr_type(struct guest_info * info) {
 
 
 
-int injecting_intr(struct guest_info * info, uint_t intr_num, intr_type_t type) {
+int v3_injecting_intr(struct guest_info * info, uint_t intr_num, intr_type_t type) {
   struct v3_intr_state * intr_state = &(info->intr_state);
 
   if (type == EXCEPTION) {