Re: [PATCH] KVM: Send reschedule IPIs instead of SMP function calls for non-waiting requests
From: Satish Kharat
Date: Wed Nov 18 2026 - 16:12:15 EST
Hi Sean,
I tested this in place of my IRQ-bypass patch. The latter was reverted in
the test source, and I loaded a kvm.ko built with your change against the
running test kernel.
On an Intel UCS C220 M7, a four-vCPU guest used an ENIC VF through VFIO.
With the other three vCPUs busy, reloading the guest VF driver traced
vfio_msi_set_vector_signal() through vt_pi_start_bypass() to
kvm_make_all_cpus_request() with local IRQs disabled. The trace then showed
three reschedule IPIs from kvm_make_vcpu_request(), with no SMP function
call in that callback and no warning. Posted-interrupt updates occurred.
Three more VF reload cycles passed bidirectional traffic after VF traffic
became ready.
On an Intel UCS C240 M6 with the same test kernel and patched kvm.ko,
irqfd_test, irq_test, vmx_posted_intr_test and smptest passed. I restored
the original KVM modules on both hosts after testing.
One source-review question: should the direct IPI path check
cpu_online(cpu), as __kvm_vcpu_kick() does? The old batched helper filters
offline CPUs, while x86 native_smp_send_reschedule() warns for one. A
target vCPU could leave guest mode and its CPU could go offline between
the request check and the IPI. I did not test CPU hotplug, and this would
not imply a lost request.
Tested-by: Satish Kharat <satishkh@xxxxxxxxx>