Re: [PATCH v3 2/2] s390/pci: Migrate s390 IRQ logic to IRQ domain API

From: Thomas Gleixner

Date: Wed Nov 19 2025 - 10:35:10 EST


On Wed, Nov 19 2025 at 11:12, Tobias Schumacher wrote:
> Am 2025-11-18 22:49, schrieb Farhan Ali:
>> Also thinking it out loud, is it this going to be unique if we have
>> multiple IRQ (if nr_irqs in zpci_msi_domain_alloc() is > 1) per MSI
>> descriptor, unless I missed something?
>
> AFAIU also for MSI there is one MSI descriptor per IRQ (allocated in
> msi_domain_alloc_simple_msi_descs()).

Correct because MSI only stores the MSI message for the index=0. If
there are multiple interrupts in the device then the MSI controller adds
the index of the interrupt to be raised in the lower bits of msi_msg::data

> The MSI index is incremented with each descriptor. We could iterate
> these descriptors, but since the index is incremented with each desc
> alloc() simply implements a for loop that increments the hwirq number
> for each irq.

That's correct because the MSI controller in the PCI device requires
that the hardware interrupt numbers are consecutive due to the above.

Thanks,

tglx