]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: nVMX: Reset vmxon_ptr upon VMXOFF emulation.
authorVitaly Kuznetsov <vkuznets@redhat.com>
Wed, 29 Sep 2021 17:51:54 +0000 (01:51 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 30 Sep 2021 08:27:02 +0000 (04:27 -0400)
commitbd9a426d6929bbf315dbc6fede056e5e714045f8
treec09ce06c684d580a77ba854ef1cd1e3675037454
parentbd52d43148d8adbcf4cc58a867a8719ea19e6a58
KVM: nVMX: Reset vmxon_ptr upon VMXOFF emulation.

Currently, 'vmx->nested.vmxon_ptr' is not reset upon VMXOFF
emulation. This is not a problem per se as we never access
it when !vmx->nested.vmxon. But this should be done to avoid
any issue in the future.

Also, initialize the vmxon_ptr when vcpu is created.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Yu Zhang <yu.c.zhang@linux.intel.com>
Message-Id: <20210929175154.11396-3-yu.c.zhang@linux.intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx/nested.c
arch/x86/kvm/vmx/vmx.c