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 the framework for interupt delivery
[palacios.git] / palacios / include / palacios / vmm_intr.h
index 9751807..0b178b0 100644 (file)
@@ -1,7 +1,47 @@
 #ifndef __VMM_INTR_H
 #define __VMM_INTR_H
 
+#include <palacios/vmm_types.h>
 
+#define DE_EXCEPTION          0x00  
+#define DB_EXCEPTION          0x01
+#define NMI_EXCEPTION         0x02
+#define BP_EXCEPTION          0x03
+#define OF_EXCEPTION          0x04
+#define BR_EXCEPTION          0x05
+#define UD_EXCEPTION          0x06
+#define NM_EXCEPTION          0x07
+#define DF_EXCEPTION          0x08
+#define TS_EXCEPTION          0x0a
+#define NP_EXCEPTION          0x0b
+#define SS_EXCEPTION          0x0c
+#define GPF_EXCEPTION         0x0d
+#define PF_EXCEPTION          0x0e
+#define MF_EXCEPTION          0x10
+#define AC_EXCEPTION          0x11
+#define MC_EXCEPTION          0x12
+#define XF_EXCEPTION          0x13
+#define SX_EXCEPTION          0x1e
+
+
+typedef enum {INVALID_INTR, EXTERNAL_IRQ, NMI, EXCEPTION, SOFTWARE, VIRTUAL} intr_types_t;
+
+struct guest_info;
+
+struct vm_intr {
+  uint_t excp_pending;
+  uint_t excp_num;
+  
+  /* some way to get the [A]PIC intr */
+
+};
+
+
+int raise_exception(struct guest_info * info, uint_t excp);
+
+int intr_pending(struct vm_intr * intr);
+uint_t get_intr_number(struct vm_intr * intr);
+intr_types_t get_intr_type(struct vm_intr * intr);
 
 
 #endif