can: m_can: fix periph RX path: use rx-offload to ensure skbs are sent from softirq...
authorTorin Cooper-Bennun <torin@maxiluxsystems.com>
Mon, 8 Mar 2021 10:24:28 +0000 (10:24 +0000)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Tue, 30 Mar 2021 09:14:48 +0000 (11:14 +0200)
commit1be37d3b0414e3db47f6fcba6c16286bbae0cb65
tree59b324da8bac464bce50b894b6c2884540b8072c
parentdf06fd678260bca919ea894281ec54ce10e45ce6
can: m_can: fix periph RX path: use rx-offload to ensure skbs are sent from softirq context

For peripheral devices, m_can sent skbs directly from a threaded irq
instead of from a softirq context, breaking the tcan4x5x peripheral
driver completely. This patch transitions the driver to use the
rx-offload helper for peripherals, ensuring the skbs are sent from the
correct context, with h/w timestamping to ensure correct ordering.

Link: https://lore.kernel.org/r/20210308102427.63916-4-torin@maxiluxsystems.com
Signed-off-by: Torin Cooper-Bennun <torin@maxiluxsystems.com>
[mkl: m_can_class_register(): update error handling]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/m_can/m_can.c
drivers/net/can/m_can/m_can.h