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.


Changes for software interrupt extension code
[palacios.git] / palacios / src / palacios / svm_handler.c
index a84d2e1..1854c53 100644 (file)
@@ -43,7 +43,9 @@
 #include <palacios/vmm_telemetry.h>
 #endif
 
-
+#ifdef V3_CONFIG_EXT_SW_INTERRUPTS
+#include <interfaces/sw_intr.h>
+#endif
 
 int v3_handle_svm_exit(struct guest_info * info, addr_t exit_code, addr_t exit_info1, addr_t exit_info2) {
 
@@ -275,6 +277,17 @@ int v3_handle_svm_exit(struct guest_info * info, addr_t exit_code, addr_t exit_i
            // Force exit on other cores
 
            break;
+#ifdef V3_CONFIG_EXT_SW_INTERRUPTS
+    case VMEXIT_SWINT:
+#ifdef V3_CONFIG_DEBUG_EXT_SW_INTERRUPTS
+        PrintDebug("Intercepted a software interrupt\n");
+#endif
+        if (v3_handle_swintr(info) == -1) {
+            PrintError("Error handling software interrupt\n");
+            return -1;
+        }
+        break;
+#endif
 
 
            /* Exits Following this line are NOT HANDLED */