]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
can: dev: can_restart(): move debug message and stats after successful restart
authorMarc Kleine-Budde <mkl@pengutronix.de>
Fri, 29 Sep 2023 08:18:02 +0000 (10:18 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Aug 2025 10:04:47 +0000 (12:04 +0200)
commit9033f4cec33ac64a4faab92d89c5026efad3e702
tree39cff7f73e2dd74c474235294f7554d0c16d2fe6
parent0a26f3a3ed52e511fb086e1c8b6cb43a63ada69c
can: dev: can_restart(): move debug message and stats after successful restart

[ Upstream commit f0e0c809c0be05fe865b9ac128ef3ee35c276021 ]

Move the debug message "restarted" and the CAN restart stats_after_
the successful restart of the CAN device, because the restart may
fail.

While there update the error message from printing the error number to
printing symbolic error names.

Link: https://lore.kernel.org/all/20231005-can-dev-fix-can-restart-v2-4-91b5c1fd922c@pengutronix.de
Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
[mkl: mention stats in subject and description, too]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Stable-dep-of: c1f3f9797c1f ("can: netlink: can_changelink(): fix NULL pointer deref of struct can_priv::do_set_mode")
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/can/dev/dev.c