Re: [PATCH v5 0/2] genirq: s390/pci: Migrate MSI interrupts to irqdomain API

From: Niklas Schnelle

Date: Fri Nov 21 2025 - 06:03:38 EST


On Fri, 2025-11-21 at 06:32 +0100, Tobias Schumacher wrote:
> This patch series reworks the PCIe interrupt handling on s390 by
> migrating it to use a proper MSI parent domain. Introducing a dedicated
> MSI domain hierarchy aligns s390 PCIe support with the generic Linux IRQ
> domain model. Currently s390 is one of the last architectures still using
> the legacy API.
>
> The migration splits the existing code in the legacy functions
> arch_setup_msi_irqs() and arch_teardown_msi_irqs() into different
> callbacks of the newly created MSI parent domain:
>
> - zpci_msi_prepare(): prepare the allocation of per-device MSI IRQs.
> will be called once for each device before allocating individual
> IRQs and sets up for example the adapter aisb and aibv.
> - zpci_msi_teardown(): reverts the effects of zpci_msi_prepare() and is
> called after all MSI IRQs are freed.
> - zpci_msi_domain_alloc(): the allocation function for interrupts
> - zpci_msi_domain_free(): revert the effects of zpci_msi_domain_alloc()
> - zpci_compose_msi_msg(): create the MSI message to be written into the
> corresponding PCI config space.
>
> * Patch 1 fixes an inconsistency in the irqdomain API. Internally, hw
> irqs are represented by an unsigned long int (irq_hw_number_t) while
> the external API in some cases takes an unsigned int as parameter.
> This fix was required in V2 of the patchset. Due to conceptual changes
> in patch 2 it is not required anymore for s390, but still seems
> sensible.
> * Patch 2 implements IRQ domains for s390 PCI
>
> Since patch 1 changes common APIs, some build tests were done for x86_64
> and arm64.
>
> Signed-off-by: Tobias Schumacher <ts@xxxxxxxxxxxxx>
> ---

@Heiko, @Vasily, @Alexander, from my point of view this series is ready
to be picked up for the s390 tree and would also benefit from time on
linux-next etc.

Thanks,
Niklas