kernel_samsung_a53x/drivers/net/can
Marc Kleine-Budde 0fd677f8d4 can: m_can: m_can_close(): stop clocks after device has been shut down
[ Upstream commit 2c09b50efcad985cf920ca88baa9aa52b1999dcc ]

After calling m_can_stop() an interrupt may be pending or NAPI might
still be executed. This means the driver might still touch registers
of the IP core after the clocks have been disabled. This is not good
practice and might lead to aborts depending on the SoC integration.

To avoid these potential problems, make m_can_close() symmetric to
m_can_open(), i.e. stop the clocks at the end, right before shutting
down the transceiver.

Fixes: e0d1f4816f2a ("can: m_can: add Bosch M_CAN controller support")
Link: https://patch.msgid.link/20240910-can-m_can-fix-ifup-v3-2-6c1720ba45ce@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:21:18 +01:00
..
c_can Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cc770 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dev can: dev: can_restart(): fix race condition between controller restart and netif_carrier_on() 2024-11-18 11:42:49 +01:00
ifi_canfd Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
m_can can: m_can: m_can_close(): stop clocks after device has been shut down 2024-11-23 23:21:18 +01:00
mscan Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
peak_canfd Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
rcar Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sja1000 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
softing Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
spi can: mcp251x: fix deadlock if an interrupt occurs during mcp251x_open 2024-11-23 23:21:00 +01:00
usb can: kvaser_usb: fix return value for hif_usb_send_regout 2024-11-19 14:19:48 +01:00
at91_can.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
flexcan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
grcan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
janz-ican3.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
kvaser_pciefd.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
led.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pch_can.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
slcan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sun4i_can.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ti_hecc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
vcan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
vxcan.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
xilinx_can.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00