summaryrefslogtreecommitdiff
path: root/drivers/net/can/m_can
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2019-10-09 07:41:08 +0300
committerMarc Kleine-Budde <mkl@pengutronix.de>2021-07-25 12:36:25 +0300
commitc757096ea1033c46ab768709847f7776b7e92a92 (patch)
tree4266fd517670b9a1c62c49a8375ee5139470199b /drivers/net/can/m_can
parenta08ec5fe709fe0d9fbd524ca6dcf6c41320d5bf3 (diff)
downloadlinux-c757096ea1033c46ab768709847f7776b7e92a92.tar.xz
can: rx-offload: add skb queue for use during ISR
Adding a skb to the skb_queue in rx-offload requires to take a lock. This commit avoids this by adding an unlocked skb queue that is appended at the end of the ISR. Having one lock at the end of the ISR should be OK as the HW is empty, not about to overflow. Link: https://lore.kernel.org/r/20210724204745.736053-2-mkl@pengutronix.de Tested-by: Oleksij Rempel <o.rempel@pengutronix.de> Co-developed-by: Kurt Van Dijck <dev.kurt@vandijck-laurijssen.be> Signed-off-by: Kurt Van Dijck <dev.kurt@vandijck-laurijssen.be> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/net/can/m_can')
-rw-r--r--drivers/net/can/m_can/m_can.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c
index bba2a449ac70..18461982f7a1 100644
--- a/drivers/net/can/m_can/m_can.c
+++ b/drivers/net/can/m_can/m_can.c
@@ -1058,6 +1058,9 @@ static irqreturn_t m_can_isr(int irq, void *dev_id)
}
}
+ if (cdev->is_peripheral)
+ can_rx_offload_irq_finish(&cdev->offload);
+
return IRQ_HANDLED;
}