summaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/vmx.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman2017-05-22 08:56:55 +0200
committerGreg Kroah-Hartman2017-05-22 08:56:55 +0200
commitb4a338d2b3cafa1be68d4e1903203c7e08a38ee5 (patch)
tree069f3753af1cda34c36a7627000ab46ef5c51c83 /arch/x86/kvm/vmx.c
parentmisc: sram-exec: Use aligned fncpy instead of memcpy (diff)
parentLinux 4.12-rc2 (diff)
downloadkernel-qcow2-linux-b4a338d2b3cafa1be68d4e1903203c7e08a38ee5.tar.gz
kernel-qcow2-linux-b4a338d2b3cafa1be68d4e1903203c7e08a38ee5.tar.xz
kernel-qcow2-linux-b4a338d2b3cafa1be68d4e1903203c7e08a38ee5.zip
Merge 4.12-rc2 into char-misc-next
We want the fixes in here as well to handle merge issues. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/x86/kvm/vmx.c')
-rw-r--r--arch/x86/kvm/vmx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index c6f4ad44aa95..72f78396bc09 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -6504,7 +6504,7 @@ static __init int hardware_setup(void)
enable_ept_ad_bits = 0;
}
- if (!cpu_has_vmx_ept_ad_bits())
+ if (!cpu_has_vmx_ept_ad_bits() || !enable_ept)
enable_ept_ad_bits = 0;
if (!cpu_has_vmx_unrestricted_guest())
@@ -11213,7 +11213,7 @@ static int vmx_write_pml_buffer(struct kvm_vcpu *vcpu)
if (!nested_cpu_has_pml(vmcs12))
return 0;
- if (vmcs12->guest_pml_index > PML_ENTITY_NUM) {
+ if (vmcs12->guest_pml_index >= PML_ENTITY_NUM) {
vmx->nested.pml_full = true;
return 1;
}