--- /dev/null
+#ifndef __VMM_DEV_H
+#define __VMM_DEV_H
+
+
+
+struct vm_device {
+  int (*init_device
+
+
+};
+
+
+
+
+
+#endif
 
 struct vm_intr {
   uint_t excp_pending;
   uint_t excp_num;
+  uint_t excp_error_code;
   
   /* some way to get the [A]PIC intr */
 
 };
 
 
+void init_interrupt_state(struct vm_intr * state);
+
 int raise_exception(struct guest_info * info, uint_t excp);
 
 int intr_pending(struct vm_intr * intr);
 
     vm_info.cpu_mode = REAL;
 
     init_vmm_io_map(&(vm_info.io_map));
+    init_interrupt_state(&(vm_info.intr_state));
 
     
     if (0) {
 
       break;
     case EXCEPTION:
       guest_ctrl->EVENTINJ.type = SVM_INJECTION_EXCEPTION;
+      guest_ctrl->EVENTINJ.excp_error_code = info->intr_state.excp_error_code;
       break;
     case SOFTWARE:
       guest_ctrl->EVENTINJ.type = SVM_INJECTION_SOFT_INTR;
 
     case INVALID_INTR: 
     default:
-      PrintDebug("Attempted to issue and invalid interrupt\n");
+      PrintDebug("Attempted to issue an invalid interrupt\n");
       return -1;
     }
 
     // IMPORTANT TODO
     // We need to figure out stack parameters....
-    // EVENTINJ.error_code
+
+    //EVENTINJ.error_code
 
   }
 
 
 #include <palacios/vmm_intr.h>
 #include <palacios/vm_guest.h>
 
+
+void init_interrupt_state(struct vm_intr * state) {
+  state->excp_pending = 0;
+  state->excp_num = 0;
+  state->excp_error_code = 0;
+}
+
 int raise_exception(struct guest_info * info, uint_t excp) {
 
   /* We can't stack exceptions,