KVM: nVMX: Move reflection check into nested_vmx_reflect_vmexit()
authorSean Christopherson <sean.j.christopherson@intel.com>
Wed, 15 Apr 2020 17:55:10 +0000 (10:55 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 21 Apr 2020 13:13:01 +0000 (09:13 -0400)
commit789afc5ccd4ef1374669f788c90a870d4e41074c
tree145f2e6033cc468ac984f8dbe11ddcca74b1453b
parent812756a82ea51e3c7ff7ba5e6fa3f34345234bc7
KVM: nVMX: Move reflection check into nested_vmx_reflect_vmexit()

Move the call to nested_vmx_exit_reflected() from vmx_handle_exit() into
nested_vmx_reflect_vmexit() and change the semantics of the return value
for nested_vmx_reflect_vmexit() to indicate whether or not the exit was
reflected into L1.  nested_vmx_exit_reflected() and
nested_vmx_reflect_vmexit() are intrinsically tied together, calling one
without simultaneously calling the other makes little sense.

No functional change intended.

Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Sean Christopherson <sean.j.christopherson@intel.com>
Message-Id: <20200415175519.14230-2-sean.j.christopherson@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx/nested.h
arch/x86/kvm/vmx/vmx.c