qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] Fix nmi injection failure when vcpu got blocked


From: Radim Krčmář
Subject: Re: [Qemu-devel] [PATCH] Fix nmi injection failure when vcpu got blocked
Date: Wed, 24 May 2017 16:34:19 +0200

Please use tags in patches.
We usually begin the subject with "KVM: x86:" when touching
arch/x86/kvm/x86.c.

2017-05-24 13:48+0800, Zhuangyanying:
> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
> @@ -8394,7 +8394,8 @@ static inline bool kvm_vcpu_has_events(struct kvm_vcpu 
> *vcpu)
>       if (vcpu->arch.pv.pv_unhalted)
>               return true;
>  
> -     if (atomic_read(&vcpu->arch.nmi_queued))
> +     if (vcpu->arch.nmi_pending ||
> +         atomic_read(&vcpu->arch.nmi_queued))
>               return true;

Hm, I think we've been missing '&& kvm_x86_ops->nmi_allowed(vcpu)'.

The undesired resume if we have suppressed NMI is not making it much
worse, but wouldn't "kvm_test_request(KVM_REQ_NMI, vcpu)" also work
here?

>       if (kvm_test_request(KVM_REQ_SMI, vcpu))

Thanks.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]