[PATCH v2 2/3] KVM: x86: Reevaluate pending interrupts when hardware-disabling the local APIC
From: Jiaming Fan
Date: Thu Nov 26 2026 - 08:49:18 EST
Hardware-disabling the APIC through IA32_APIC_BASE turns LINT0 into the
INTR pin, so a PIC interrupt latched while LVT0 was masked becomes
injectable. As with unmasking LVT0, KVM must request KVM_REQ_EVENT, or
the interrupt is never injected.
Signed-off-by: Jiaming Fan <fan.jiaming@xxxxxxxxxxx>
---
arch/x86/kvm/lapic.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c
index c1f819a0ab2fd..86206cd47bc61 100644
--- a/arch/x86/kvm/lapic.c
+++ b/arch/x86/kvm/lapic.c
@@ -2827,6 +2827,7 @@ static void __kvm_apic_set_base(struct kvm_vcpu *vcpu, u64 value)
} else {
static_branch_inc(&apic_hw_disabled.key);
atomic_set_release(&apic->vcpu->kvm->arch.apic_map_dirty, DIRTY);
+ kvm_make_request(KVM_REQ_EVENT, vcpu);
}
}
--
2.56.1