KVM: VMX: check nested state and CR4.VMXE against SMM
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 18 Sep 2018 13:19:17 +0000 (15:19 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 19 Sep 2018 22:51:43 +0000 (00:51 +0200)
commit5bea5123cbf08f990a1aee8f08c643a272e06a0f
treec520f5be46b2bb5f135413bfe85bf9518675310c
parent822f312d47f0200dc0999c9f006fe94aa43bd0bd
KVM: VMX: check nested state and CR4.VMXE against SMM

VMX cannot be enabled under SMM, check it when CR4 is set and when nested
virtualization state is restored.

This should fix some WARNs reported by syzkaller, mostly around
alloc_shadow_vmcs.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx.c