]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
iommu/riscv: Skip IRQ count check when using MSI interrupts
authorYaxing Guo <guoyaxing@bosc.ac.cn>
Fri, 30 Jan 2026 06:54:20 +0000 (14:54 +0800)
committerJoerg Roedel <joerg.roedel@amd.com>
Tue, 17 Mar 2026 12:12:17 +0000 (13:12 +0100)
commit7217cee35aadbb07e12673bcf1dcf729e1b2f6c9
tree5131a31af6e5c6639b1c4bbbaa714d0257c2ccd0
parentf5c262b544975e067ea265fc7403aefbbea8563e
iommu/riscv: Skip IRQ count check when using MSI interrupts

In RISC-V IOMMU platform devices that use MSI interrupts (indicated by the
presence of 'msi-parent' in the device tree), there are no wired interrupt
lines, so calling platform_get_irq_count() returns 0 or -ENXIO, causing the
driver to fail during probe.

However, MSI interrupts are allocated dynamically via the MSI subsystem and
do not appear in the device tree 'interrupts' property. Therefore, the
driver should not require a non-zero IRQ count when 'msi-parent' is present.

This patch fixes the bug where probe fails when using MSI interrupts
 (which do not have an 'interrupts' property in the device tree)..

Fixes: <d5f88acdd6ff> ("iommu/riscv: Add support for platform msi")
Signed-off-by: Yaxing Guo <guoyaxing@bosc.ac.cn>
Reviewed-by: Andrew Jones <andrew.jones@oss.qualcomm.com>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
drivers/iommu/riscv/iommu-platform.c