Skip to content

x86/x86: KVM: Fixes for KVM's PI wakeup handler

Sean Christopherson kvm lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4x86/irq: Ensure PI wakeup handler is unregistered before module unloadarch/x86/kernel/irq.c+1 -00 replies
2/4KVM: VMX: Unregister posted interrupt wakeup handler on hardware unsetuparch/x86/kvm/vmx/vmx.c+5 -20 replies
3/4x86/irq: KVM: Harden posted interrupt (un)registration pathsarch/x86/include/asm/irq.h arch/x86/kernel/irq.c arch/x86/kvm/vmx/vmx.c+24 -121 reply
4/4KVM: VMX: Register posted interrupt wakeup handler iff APICv is enabledarch/x86/kvm/vmx/vmx.c+4 -21 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] x86/x86: KVM: Fixes for KVM's PI wakeup handler

Two fixes and two cleanups related to KVM's posted interrupt wakeup handler. Fix #1 ensures any in-flight IRQs finish after changing the handler. Fix #2 actually uninstalls KVM's handler so that a spurious IRQ won't jump into a freed module.

AFAIK, no one has actually hit these bugs as it would require a really spurious IRQ, or a bug+race elsehwere that caused a device to post an interrupt well after a KVM guest is torn down.

Sean Christopherson (4):
x86/irq: Ensure PI wakeup handler is unregistered before module unload
KVM: VMX: Unregister posted interrupt wakeup handler on hardware
unsetup
x86/irq: KVM: Harden posted interrupt (un)registration paths
KVM: VMX: Register posted interrupt wakeup handler iff APICv is
enabled

 arch/x86/include/asm/irq.h |  3 ++-
 arch/x86/kernel/irq.c      | 30 +++++++++++++++++++++---------
 arch/x86/kvm/vmx/vmx.c     |  9 +++++++--
 3 files changed, 30 insertions(+), 12 deletions(-)
Signature · 1 line
2.33.0.882.g93a45727a2-goog