Hi Michael, > Il 23/09/2022 13:36 Marc Kleine-Budde <mkl@xxxxxxxxxxxxxx> ha scritto: > > > On 16.09.2022 06:14:58, Jacob Kroon wrote: > > What I do know is that if I revert commit: > > > > "can: c_can: cache frames to operate as a true FIFO" > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=387da6bc7a826cc6d532b1c0002b7c7513238d5f > > > > then everything looks good. I don't get any BUG messages, and the host > > has been running overnight without problems, so it seems to have fixed > > the network interface lockup as well. > > Jacob, after this mail, I'll send 2 patches. One tries to disable the > cache feature for C_CAN cores, the other shuts a potential race window. About the "can: c_can: don't cache TX messages for C_CAN cores" patch: Could it make sense to change the c_can_start_xmit in this way - if (idx < c_can_get_tx_tail(tx_ring)) - cmd &= ~IF_COMM_TXRQST; /* Cache the message */ + if (idx < c_can_get_tx_tail(tx_ring)) { + if (priv->type == BOSCH_D_CAN) { + cmd &= ~IF_COMM_TXRQST; /* Cache the message */ + } else { + netif_stop_queue(priv->dev); + return NETDEV_TX_BUSY; + } + } without changing the c_can_get_tx_{free,busy} routines ? Thanks and regards, Dario > Please test both patches, but only apply one of them at a time. :) > > regards, > Marc > > -- > Pengutronix e.K. | Marc Kleine-Budde | > Embedded Linux | https://www.pengutronix.de | > Vertretung West/Dortmund | Phone: +49-231-2826-924 | > Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |