diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2015-10-19 12:30:19 +0300 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2015-10-19 12:34:45 +0300 |
commit | 5690891bcec5fcfda38da974ffa5488e36a59811 (patch) | |
tree | 4bf44c8670a54a417c5738149290e31aaeae7916 /arch/x86/kvm/vmx.c | |
parent | f33143d80907602deb1b96db42da93507ed03b31 (diff) | |
download | linux-5690891bcec5fcfda38da974ffa5488e36a59811.tar.xz |
kvm: x86: zero EFER on INIT
Not zeroing EFER means that a 32-bit firmware cannot enter paging mode
without clearing EFER.LME first (which it should not know about).
Yang Zhang from Intel confirmed that the manual is wrong and EFER is
cleared to zero on INIT.
Fixes: d28bc9dd25ce023270d2e039e7c98d38ecbf7758
Cc: stable@vger.kernel.org
Cc: Yang Z Zhang <yang.z.zhang@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/kvm/vmx.c')
-rw-r--r-- | arch/x86/kvm/vmx.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c index 15bff51d492a..4d0aa31a42ba 100644 --- a/arch/x86/kvm/vmx.c +++ b/arch/x86/kvm/vmx.c @@ -4932,8 +4932,7 @@ static void vmx_vcpu_reset(struct kvm_vcpu *vcpu, bool init_event) vmx_set_cr0(vcpu, cr0); /* enter rmode */ vmx->vcpu.arch.cr0 = cr0; vmx_set_cr4(vcpu, 0); - if (!init_event) - vmx_set_efer(vcpu, 0); + vmx_set_efer(vcpu, 0); vmx_fpu_activate(vcpu); update_exception_bitmap(vcpu); |