RE: [PATCH v3 1/3] x86/hyperv: Set irq_retrigger for root partition PCI/MSI irqchip

From: Michael Kelley

Date: Mon Sep 07 2026 - 15:54:59 EST


From: Naman Jain <namjain@xxxxxxxxxxxxxxxxxxx> Sent: Sunday, September 6, 2026 11:51 PM
>
> The Hyper-V root partition vPCI MSI irqchip lost its irq_retrigger()
> callback when it was converted to msi_create_parent_irq_domain(). The
> callback was present on the original irqchip and was dropped during that
> conversion.
>
> On CPU hot-unplug fixup_irqs() migrates the interrupts which are affine to
> the outgoing CPU to a new target. If an interrupt still has its pending bit
> set in the outgoing CPU's IRR at that point, fixup_irqs() resends it on the
> new target through the irqchip's irq_retrigger() callback. As the root
> partition PCI/MSI chip no longer provides that callback, the pending
> interrupt is silently dropped, which can result in lost interrupts, stalls
> and "No irq handler for vector" messages during CPU hotplug.
>
> Restore irq_chip_retrigger_hierarchy() as the irq_retrigger() callback for
> the root partition PCI/MSI irqchip, so that a pending interrupt is resent
> on its new target CPU via the parent x86 vector domain.
>
> Fixes: 4691db0704ac ("x86/hyperv: Switch to msi_create_parent_irq_domain()")
> Cc: stable@xxxxxxxxxxxxxxx
> Signed-off-by: Naman Jain <namjain@xxxxxxxxxxxxxxxxxxx>
> ---
> arch/x86/hyperv/irqdomain.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/arch/x86/hyperv/irqdomain.c b/arch/x86/hyperv/irqdomain.c
> index b3ad50a874dca..1e273d7d6c5b3 100644
> --- a/arch/x86/hyperv/irqdomain.c
> +++ b/arch/x86/hyperv/irqdomain.c
> @@ -304,6 +304,7 @@ static struct irq_chip hv_pci_msi_controller = {
> .irq_ack = irq_chip_ack_parent,
> .irq_compose_msi_msg = hv_irq_compose_msi_msg,
> .irq_set_affinity = irq_chip_set_affinity_parent,
> + .irq_retrigger = irq_chip_retrigger_hierarchy,
> };

There's a slight discrepancy compared with the guest pci-hyperv.c driver,
where setting the .irq_retrigger function is done dynamically in
hv_pcie_init_dev_msi_info() instead of statically. The parallel here would
be to set it in hv_init_dev_msi_info(). But given that Patch 3 of series
removes setting .irq_retrigger in both cases, the discrepancy shouldn't
really matter.

If there's a reason to prefer one approach vs. the other, I don't know
what that reason is.

Reviewed-by: Michael Kelley <mhklinux@xxxxxxxxxxx>

>
> static bool hv_init_dev_msi_info(struct device *dev, struct irq_domain *domain,
> --
> 2.43.0
>