All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 1/4] KVM: VMX: use kvm_event_needs_reinjection
@ 2017-08-24  4:21 Wanpeng Li
  2017-08-24  4:21 ` [PATCH v3 2/4] KVM: X86: Fix loss of exception which has not yet injected Wanpeng Li
                   ` (2 more replies)
  0 siblings, 3 replies; 16+ messages in thread
From: Wanpeng Li @ 2017-08-24  4:21 UTC (permalink / raw)
  To: linux-kernel, kvm; +Cc: Paolo Bonzini, Radim Krčmář, Wanpeng Li

From: Wanpeng Li <wanpeng.li@hotmail.com>

Use kvm_event_needs_reinjection() encapsulation.

Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Radim Krčmář <rkrcmar@redhat.com>
Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com>
---
 arch/x86/kvm/vmx.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index dd710d3..c5f43ab 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -10988,9 +10988,7 @@ static int vmx_check_nested_events(struct kvm_vcpu *vcpu, bool external_intr)
 {
 	struct vcpu_vmx *vmx = to_vmx(vcpu);
 
-	if (vcpu->arch.exception.pending ||
-		vcpu->arch.nmi_injected ||
-		vcpu->arch.interrupt.pending)
+	if (kvm_event_needs_reinjection(vcpu))
 		return -EBUSY;
 
 	if (nested_cpu_has_preemption_timer(get_vmcs12(vcpu)) &&
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2018-02-13 16:13 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-24  4:21 [PATCH v3 1/4] KVM: VMX: use kvm_event_needs_reinjection Wanpeng Li
2017-08-24  4:21 ` [PATCH v3 2/4] KVM: X86: Fix loss of exception which has not yet injected Wanpeng Li
2017-08-24  6:52   ` Wanpeng Li
2017-08-24  8:57     ` Paolo Bonzini
2017-08-24  9:13       ` Wanpeng Li
2017-08-24  9:34         ` Wanpeng Li
2017-08-24  9:47           ` Paolo Bonzini
2017-08-24  9:35         ` Paolo Bonzini
2017-08-24  9:47           ` Wanpeng Li
     [not found]   ` <1503548506-4457-2-git-send-email-wanpeng.li-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org>
2018-01-07  7:26     ` Ross Zwisler
2018-01-07  7:26       ` Ross Zwisler
     [not found]       ` <CAOxpaSUBf8QoOZQ1p4KfUp0jq76OKfGY4Uxs-Gg8ngReD99xww-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-09  1:24         ` Haozhong Zhang
2018-01-09  1:24           ` Haozhong Zhang
2018-02-13 16:13       ` Patch "KVM MMU: check pending exception before injecting APF" has been added to the 4.14-stable tree gregkh
2017-08-24  4:21 ` [PATCH v3 3/4] KVM: VMX: Move the nested_vmx_inject_exception_vmexit call from nested_vmx_check_exception to vmx_queue_exception Wanpeng Li
2017-08-24  4:21 ` [PATCH v3 4/4] KVM: nVMX: Fix trying to cancel vmlauch/vmresume Wanpeng Li

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.