]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
KVM: nVMX: Fix EPT switching advertising
authorWanpeng Li <wanpeng.li@hotmail.com>
Wed, 18 Oct 2017 23:00:34 +0000 (07:00 +0800)
committerRadim Krčmář <rkrcmar@redhat.com>
Fri, 20 Oct 2017 16:05:01 +0000 (18:05 +0200)
commit575b3a2cb439b03fd603ea77c73c76f3ed237596
treee74e123e56c94b426b868adf95581aef038eaf6e
parentcc3d967f7e32ceeb9b78dc962126ebcf1a2b24b2
KVM: nVMX: Fix EPT switching advertising

I can use vmxcap tool to observe "EPTP Switching   yes" even if EPT is not
exposed to L1.

EPT switching is advertised unconditionally since it is emulated, however,
it can be treated as an extended feature for EPT and it should not be
advertised if EPT itself is not exposed. This patch fixes it.

Reviewed-by: David Hildenbrand <david@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Radim Krčmář <rkrcmar@redhat.com>
Cc: Jim Mattson <jmattson@google.com>
Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
arch/x86/kvm/vmx.c