[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v1 02/21] i386/xen: Don't resample GSI when per-vCPU upcall vector is in use



On 24/11/2026 16:22, David Woodhouse wrote:
From: David Woodhouse <dwmw@xxxxxxxxxxxx>

The callback_via GSI (or PCI INTx) and the per-vCPU upcall vector are
mutually exclusive delivery mechanisms for Xen event channel upcalls.
Xen itself will never assert the callback GSI for a vCPU which has a
per-vCPU upcall vector configured.

When the interrupt is acked, QEMU's resampling logic reasserts the
GSI if evtchn_upcall_pending is still set. If the guest has configured
a per-vCPU upcall vector, events are delivered through that vector and
the GSI is unexpected; a guest which receives both the vector upcall
and a spurious GSI interrupt for the same event can crash. This was
observed in production with Windows guests on a different VMM which
implements the same resampling logic.

If a per-vCPU upcall vector is configured, don't resample the GSI;
just deassert it.

Fixes: ddf0fd9ae1fd ("hw/xen: Support HVM_PARAM_CALLBACK_TYPE_GSI callback")
Signed-off-by: David Woodhouse <dwmw@xxxxxxxxxxxx>
---
  target/i386/kvm/xen-emu.c | 7 +++++++
  1 file changed, 7 insertions(+)

Reviewed-by: Paul Durrant <paul@xxxxxxx>



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.