[PATCH 4/8] irqchip/imx-intmux: Don't WARN on malformed interrupt specifiers
From: Peng Fan
Date: Tue Nov 17 2026 - 02:14:56 EST
From: Peng Fan <peng.fan@xxxxxxx>
The xlate callback validates the interrupt specifier cells, but uses
WARN_ON() for checks that can be triggered by user-supplied device tree
data. A malformed specifier is an expected, recoverable error, so the
WARN only floods the log.
Return -EINVAL without the splat.
Signed-off-by: Peng Fan <peng.fan@xxxxxxx>
---
drivers/irqchip/irq-imx-intmux.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/irqchip/irq-imx-intmux.c b/drivers/irqchip/irq-imx-intmux.c
index c7b6b475bfb9..31fd895f477b 100644
--- a/drivers/irqchip/irq-imx-intmux.c
+++ b/drivers/irqchip/irq-imx-intmux.c
@@ -144,10 +144,10 @@ static int imx_intmux_irq_xlate(struct irq_domain *d, struct device_node *node,
* the 1st cell: hw interrupt number
* the 2nd cell: channel index
*/
- if (WARN_ON(intsize != 2))
+ if (intsize != 2)
return -EINVAL;
- if (WARN_ON(intspec[1] >= data->channum))
+ if (intspec[1] >= data->channum)
return -EINVAL;
*out_hwirq = intspec[0];
--
2.56.0