Kernel KVM virtualization development
 help / color / mirror / Atom feed
* [PATCH v2 0/2] KVM: x86: Fix max_irr reporting when PIR is empty despite PID.ON
@ 2026-04-29  7:28 Chenyi Qiang
  2026-04-29  7:28 ` [PATCH v2 1/2] KVM: x86: Always report highest IRR from __kvm_apic_update_irr() Chenyi Qiang
  2026-04-29  7:28 ` [PATCH v2 2/2] KVM: x86: Fix misleading variable names and add more comments for PIR=>IRR flow Chenyi Qiang
  0 siblings, 2 replies; 3+ messages in thread
From: Chenyi Qiang @ 2026-04-29  7:28 UTC (permalink / raw)
  To: kvm; +Cc: Chenyi Qiang, Sean Christopherson, Jim Mattson, Paolo Bonzini,
	Gao Chao

Fix a race in the PIR-to-IRR synchronization path where PID.ON is set
but PIR is empty, causing __kvm_apic_update_irr() to report max_irr as
-1 even though there are pending interrupts in the IRR.  This triggers a
spurious WARNING in vmx_check_nested_events() during nested VM stress
tests.

v2:
  - Move the fix from vmx_sync_pir_to_irr() to __kvm_apic_update_irr()
    as suggested by Paolo along with some commit message changes. [Paolo]
  - Add Cc: stable, Suggested-by, Reviewed-by tags.
  - Carry Sean's cleanup patch for variable renames and expanded
    comments. [Sean]

v1: https://lore.kernel.org/kvm/20260428070349.1633238-1-chenyi.qiang@intel.com/

Chenyi Qiang (1):
  KVM: x86: Always report highest IRR from __kvm_apic_update_irr()

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.43.5


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

end of thread, other threads:[~2026-04-29  7:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-29  7:28 [PATCH v2 0/2] KVM: x86: Fix max_irr reporting when PIR is empty despite PID.ON Chenyi Qiang
2026-04-29  7:28 ` [PATCH v2 1/2] KVM: x86: Always report highest IRR from __kvm_apic_update_irr() Chenyi Qiang
2026-04-29  7:28 ` [PATCH v2 2/2] KVM: x86: Fix misleading variable names and add more comments for PIR=>IRR flow Chenyi Qiang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox