Re: [PATCH net-next 07/12] can: at91_can: don't discard the IRQ lookup error in probe

From
netdev-bot+sashiko@kernel.org
Date
2026-11-19 09:54:31
Also in
linux-can
Reply to
Marc Kleine-Budde, 2026-11-18
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] The commit message of "can: at91_can: don't discard the IRQ
  lookup error in probe" gives a real deferred-probe failure as the…

--

can: at91_can: don't discard the IRQ lookup error in probe

This commit splits the memory resource and IRQ lookups in
at91_can_probe(). A missing memory resource still returns -ENODEV, and the
error from platform_get_irq() is now passed through unchanged instead of
being collapsed into -ENODEV.

Link: https://patch.msgid.link/303815792800553c34842147941cab083823c212.1792118040.git.chaosheng.qu.linux@gmail.com (local)
The driver matches through an of_match_table, so of_irq_get() returns
-EPROBE_DEFER while the interrupt controller has not been probed. The
probe overwrites it and the driver core stops retrying, leaving the
device unbound even though the interrupt controller appears later.
[Severity: Low]
Can this deferral scenario happen with any in-tree user of this driver?

Every in-tree CAN node for this driver inherits interrupt-parent = <&aic>
from the root of at91sam9263.dtsi, at91sam9x5.dtsi, sama5d3.dtsi and
sam9x60.dtsi.

The controllers behind <&aic> all register through IRQCHIP_DECLARE:

drivers/irqchip/irq-atmel-aic.c:
    IRQCHIP_DECLARE(at91rm9200_aic, "atmel,at91rm9200-aic", aic_of_init);

drivers/irqchip/irq-atmel-aic5.c:
    IRQCHIP_DECLARE(sama5d3_aic5, "atmel,sama5d3-aic", sama5d3_aic5_of_init);
    ...
    IRQCHIP_DECLARE(sam9x60_aic5, "microchip,sam9x60-aic", sam9x60_aic5_of_init);

That means of_irq_init() sets them up from init_IRQ(), well before any
platform driver probes. So irq_find_host() in of_irq_get() should always
find the domain, and the -EPROBE_DEFER path is not reachable for this
device. The legacy non-DT path through platform_get_device_id() never
calls of_irq_get() at all.

The change itself looks fine as a consistency and robustness cleanup.
The sibling commit "can: cc770: don't discard the IRQ lookup error in
probe" has this caveat:

    This is a robustness and consistency cleanup, this issue has not been
    seen on real hardware

The commit "can: janz-ican3: don't discard the IRQ lookup error in probe"
also says it does not fix a deferred probe.

Could this message carry a similar note? As written, it reads like a fix
for an observed unbound device, and that could affect stable or AUTOSEL
backport decisions.

-- 
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261118092955.1283165-2-mkl%40pengutronix.de
Thread (22 messages) 22 messages, 4 authors, last reply 5d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help