On 25.09.2024 07:38:12, Sven Schuchmann wrote: > I am using Kernel 6.6.47 and sometimes I see this in kernel logs: > > [ 355.728634] mcp251xfd spi0.0 canfd0: IRQ handler mcp251xfd_handle_tefif() returned -22. > [ 355.728672] mcp251xfd spi0.0 canfd0: IRQ handler returned -22 (intf=0xbf1a0016). > > After that the complete CAN is down. Yes, the interface is shut down intentionally in case of errors. > ifconfig canfd0 down and up fixes the problem. That's intentional, too :) > We are using two CANs (both mcp251xfd) at the same time in canfd mode. > We are sending about 9 Frames each 10ms on both CANs (bus load of about 35% per CAN). > > Top shows about 10% of CPU Load on the SPIs: > > PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND > 5620 root -51 0 0 0 0 S 11.9 0.0 0:45.33 irq/45-spi0.0 > > Anyone an idea on this? Can you add "dev_err(&spi->dev, ... );" and print interesting things in mcp251xfd-regmap.c where it returns -EINVAL. Maybe add an additionally "dump_stack();" Have you enabled CONFIG_CAN_MCP251XFD_SANITY? If not, please do. Please also add "#define DEBUG" in mcp251xfd-tef.c before all "#includes". regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung Nürnberg | Phone: +49-5121-206917-129 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-9 |
Attachment:
signature.asc
Description: PGP signature