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.


fix the VMCS invalid field error when read VMCS_GUEST_EFER
Lei Xia [Wed, 30 Mar 2011 00:25:11 +0000 (19:25 -0500)]
palacios/include/palacios/vmx_lowlevel.h
palacios/src/palacios/vmcs.c

index 01bca79..6db9f17 100644 (file)
@@ -155,6 +155,8 @@ static inline int vmcs_read(vmcs_field_t vmcs_field, void * dst) {
         case 8:
             *((uint64_t*)dst) = (uint64_t)val;
             break;
+       default:
+            return -1;
     }
 
 
index 154bed8..9d9b40d 100644 (file)
@@ -914,10 +914,12 @@ int v3_vmcs_get_field_len(vmcs_field_t field) {
         case VMCS_HOST_SYSENTER_EIP:
         case VMCS_HOST_RSP:
         case VMCS_HOST_RIP:
+
+        case VMCS_GUEST_EFER:
             return sizeof(addr_t);
 
         default:
-           PrintError("Invalid VMCS field\n");
+           PrintError("Invalid VMCS field: 0x%x\n", field);
             return -1;
     }
 }