X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Fsrc%2Fpalacios%2Fvmx.c;h=bc45c9b444b882e33666fa869e989be46e4d13d4;hb=3e31ab96d49dcd604f85f9f81a7acc37a43ef036;hp=73b5af963324da5d9ebc61ea192535970a9a09a7;hpb=5e5c8ee949fa45116d58b904fc11aab082f61607;p=palacios.git diff --git a/palacios/src/palacios/vmx.c b/palacios/src/palacios/vmx.c index 73b5af9..bc45c9b 100644 --- a/palacios/src/palacios/vmx.c +++ b/palacios/src/palacios/vmx.c @@ -411,6 +411,11 @@ static int init_vmcs_bios(struct guest_info * core, struct vmx_data * vmx_state) v3_hook_msr(core->vm_info, SYSENTER_CS_MSR, NULL, NULL, NULL); v3_hook_msr(core->vm_info, SYSENTER_ESP_MSR, NULL, NULL, NULL); v3_hook_msr(core->vm_info, SYSENTER_EIP_MSR, NULL, NULL, NULL); + + v3_hook_msr(core->vm_info, FS_BASE_MSR, NULL, NULL, NULL); + v3_hook_msr(core->vm_info, GS_BASE_MSR, NULL, NULL, NULL); + + } /* Sanity check ctrl/reg fields against hw_defaults */ @@ -915,6 +920,12 @@ int v3_start_vmx_guest(struct guest_info * info) { PrintDebug("VMX core %u: Waiting for core initialization\n", info->vcpu_id); while (info->core_run_state == CORE_STOPPED) { + + if (info->vm_info->run_state == VM_STOPPED) { + // The VM was stopped before this core was initialized. + return 0; + } + v3_yield(info); //PrintDebug("VMX core %u: still waiting for INIT\n",info->vcpu_id); }