mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 14:56:54 -04:00
KVM: nVMX: Make event request on VMXOFF iff INIT/SIPI is pending
Explicitly check for a pending INIT/SIPI event when emulating VMXOFF instead of blindly making an event request. There's obviously no need to evaluate events if none are pending. Signed-off-by: Sean Christopherson <seanjc@google.com> Message-Id: <20220921003201.1441511-9-seanjc@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
committed by
Paolo Bonzini
parent
a56953e950
commit
ea2f00c621
@@ -5193,8 +5193,8 @@ static int handle_vmxoff(struct kvm_vcpu *vcpu)
|
||||
|
||||
free_nested(vcpu);
|
||||
|
||||
/* Process a latched INIT during time CPU was in VMX operation */
|
||||
kvm_make_request(KVM_REQ_EVENT, vcpu);
|
||||
if (kvm_apic_has_pending_init_or_sipi(vcpu))
|
||||
kvm_make_request(KVM_REQ_EVENT, vcpu);
|
||||
|
||||
return nested_vmx_succeed(vcpu);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user