]> git.ipfire.org Git - thirdparty/linux.git/commit
can: propagate CAN device capabilities via ml_priv
authorOliver Hartkopp <socketcan@hartkopp.net>
Fri, 9 Jan 2026 14:41:34 +0000 (15:41 +0100)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 15 Jan 2026 08:52:04 +0000 (09:52 +0100)
commit166e87329ce6f1eaa3475ba2d14ed30e54727c0d
tree47c59a7ce1ed0ec85ce02bb732118c70922532b7
parent4650ff58a1b9ee68b2d3a207047998dd42e939b2
can: propagate CAN device capabilities via ml_priv

Commit 1a620a723853 ("can: raw: instantly reject unsupported CAN frames")
caused a sequence of dependency and linker fixes.

Instead of accessing CAN device internal data structures which caused the
dependency problems this patch introduces capability information into the
CAN specific ml_priv data which is accessible from both sides.

With this change the CAN network layer can check the required features and
the decoupling of the driver layer and network layer is restored.

Fixes: 1a620a723853 ("can: raw: instantly reject unsupported CAN frames")
Cc: Marc Kleine-Budde <mkl@pengutronix.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Vincent Mailhol <mailhol@kernel.org>
Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Link: https://patch.msgid.link/20260109144135.8495-3-socketcan@hartkopp.net
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/dev/dev.c
drivers/net/can/dev/netlink.c
drivers/net/can/vcan.c
drivers/net/can/vxcan.c
include/linux/can/can-ml.h
include/linux/can/dev.h