From: Paolo Bonzini <pbonzini@redhat.com>
To: linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Cc: chenyi.qiang@intel.com
Subject: [PATCH 0/2] KVM: x86: Fix and clarify PIR->IRR transfer
Date: Sun, 3 May 2026 22:17:01 +0200 [thread overview]
Message-ID: <20260503201703.108231-1-pbonzini@redhat.com> (raw)
The first patch fixes a WARN in vmx_check_nested_events() due to
a specific interleaving of vmx_sync_pir_to_irr() on the target
vCPU and __vmx_deliver_posted_interrupt() on a sender vCPU.
In this case vmx_sync_pir_to_irr() sees an interrupt even before
__vmx_deliver_posted_interrupt() sets PID.ON; while this is harmless and in
fact intended, the problem is that a later call to kvm_apic_has_interrupt()
is incorrectly told that no interrupt is pending, just because PID.ON=1
but no bit set in PIR.
See original discussion at https://lore.kernel.org/kvm/20260428070349.1633238-1-chenyi.qiang@intel.com/T/.
Paolo Bonzini (1):
KVM: x86: Do IRR scan in __kvm_apic_update_irr even if PIR is empty
Sean Christopherson (1):
KVM: x86: Fix misleading variable names and add more comments for
PIR=>IRR flow
arch/x86/kvm/lapic.c | 24 +++++++++++++-----------
arch/x86/kvm/vmx/vmx.c | 40 ++++++++++++++++++++++++++++++++--------
2 files changed, 45 insertions(+), 19 deletions(-)
--
2.54.0
next reply other threads:[~2026-05-03 20:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-03 20:17 Paolo Bonzini [this message]
2026-05-03 20:17 ` [PATCH 1/2] KVM: x86: Do IRR scan in __kvm_apic_update_irr even if PIR is empty Paolo Bonzini
2026-05-03 20:17 ` [PATCH 2/2] KVM: x86: Fix misleading variable names and add more comments for PIR=>IRR flow Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260503201703.108231-1-pbonzini@redhat.com \
--to=pbonzini@redhat.com \
--cc=chenyi.qiang@intel.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox