linux-stable/drivers/net/can
Marc Kleine-Budde fe5c9940df can: dev: can_restart(): don't crash kernel if carrier is OK
During testing, I triggered a can_restart() with the netif carrier
being OK [1]. The BUG_ON, which checks if the carrier is OK, results
in a fatal kernel crash. This is neither helpful for debugging nor for
a production system.

[1] The root cause is a race condition in can_restart() which will be
fixed in the next patch.

Do not crash the kernel, issue an error message instead, and continue
restarting the CAN device anyway.

Fixes: 39549eef35 ("can: CAN Network device driver and Netlink interface")
Link: https://lore.kernel.org/all/20231005-can-dev-fix-can-restart-v2-1-91b5c1fd922c@pengutronix.de
Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2023-10-05 21:32:12 +02:00
..
c_can can: c_can: Do not check for 0 return after calling platform_get_irq() 2023-08-02 08:19:20 +02:00
cc770 can: cc770_platform: Convert to platform remove callback returning void 2023-05-15 22:53:49 +02:00
ctucanfd can: ctucanfd: Convert to platform remove callback returning void 2023-05-15 22:53:50 +02:00
dev can: dev: can_restart(): don't crash kernel if carrier is OK 2023-10-05 21:32:12 +02:00
flexcan can: flexcan: fix the return value handle for platform_get_irq() 2023-07-31 10:12:56 +02:00
ifi_canfd can: Explicitly include correct DT includes, part 2 2023-07-28 08:49:52 +02:00
m_can can: tcan4x5x: Add error messages in probe 2023-07-31 10:41:09 +02:00
mscan can: mscan: mpc5xxx_can: Convert to platform remove callback returning void 2023-05-15 22:53:50 +02:00
peak_canfd can: dev: fix skb drop check 2022-11-07 14:00:27 +01:00
rcar can: Explicitly include correct DT includes, part 2 2023-07-28 08:49:52 +02:00
sja1000 can: peak_pci: replace deprecated strncpy with strscpy 2023-10-05 09:51:18 +02:00
slcan tty: use u8 for flags 2023-08-11 21:12:45 +02:00
softing can: softing: Convert to platform remove callback returning void 2023-05-15 22:53:51 +02:00
spi can: rx-offload: rename rx_offload_get_echo_skb() -> can_rx_offload_get_echo_skb_queue_timestamp() 2023-07-28 09:45:24 +02:00
usb can: etas_es58x: add missing a blank line after declaration 2023-10-04 11:46:25 +02:00
at91_can.c can: at91_can: Convert to platform remove callback returning void 2023-05-15 22:53:49 +02:00
bxcan.c can: Explicitly include correct DT includes, part 2 2023-07-28 08:49:52 +02:00
can327.c tty: use u8 for flags 2023-08-11 21:12:45 +02:00
grcan.c can: Explicitly include correct DT includes 2023-07-19 08:55:28 +02:00
janz-ican3.c can: janz-ican3: Convert to platform remove callback returning void 2023-05-15 22:53:50 +02:00
Kconfig can: sun4i_can: Add support for the Allwinner D1 2023-07-28 08:47:18 +02:00
kvaser_pciefd.c can: kvaser_pciefd: Add support for new Kvaser pciefd devices 2023-07-19 09:03:10 +02:00
Makefile can: bxcan: add support for ST bxCAN controller 2023-03-28 11:43:36 +02:00
sun4i_can.c can: Explicitly include correct DT includes, part 2 2023-07-28 08:49:52 +02:00
ti_hecc.c can: rx-offload: rename rx_offload_get_echo_skb() -> can_rx_offload_get_echo_skb_queue_timestamp() 2023-07-28 09:45:24 +02:00
vcan.c can: dev: add CAN XL support to virtual CAN 2022-09-15 09:08:09 +02:00
vxcan.c net: validate veth and vxcan peer ifindexes 2023-08-20 11:40:03 +01:00
xilinx_can.c can: xilinx_can: Add support for controller reset 2023-07-19 08:55:28 +02:00