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 TSC passthrough specification to time handling
[palacios.git] / palacios / src / palacios / svm.c
index 115a369..4d148e9 100644 (file)
@@ -353,6 +353,8 @@ int v3_init_svm_vmcb(struct guest_info * core, v3_vm_class_t vm_class) {
        return -1;
     }
 
+    core->core_run_state = CORE_STOPPED;
+
     return 0;
 }
 
@@ -527,7 +529,11 @@ v3_svm_config_tsc_virtualization(struct guest_info * info) {
     } else {
        ctrl_area->instrs.RDTSC = 0;
        ctrl_area->svm_instrs.RDTSCP = 0;
-        ctrl_area->TSC_OFFSET = v3_tsc_host_offset(&info->time_state);
+       if (info->time_state.flags & VM_TIME_TSC_PASSTHROUGH) {
+               ctrl_area->TSC_OFFSET = 0;
+       } else {
+               ctrl_area->TSC_OFFSET = v3_tsc_host_offset(&info->time_state);
+       }
     }
     return 0;
 }