linux/net/dsa
Stanislav Fomichev 0f99e0c3e1 net: dsa: remove redundant netdev_lock_ops() from conduit ethtool ops
DSA replaces the conduit (master) device's ethtool_ops with its own
wrappers that aggregate stats from both the conduit and DSA switch
ports. Taking the lock again inside the DSA wrappers causes a deadlock.

Stumbled upon this when booting qemu with fbnic and CONFIG_NET_DSA_LOOP=y
(which looks like some kind of testing device that auto-populates the ports
of eth0). `ethtool -i` is enough to deadlock. This means we have basically zero
coverage for DSA stuff with real ops locked devs.

Remove the redundant netdev_lock_ops()/netdev_unlock_ops() calls from
the DSA conduit ethtool wrappers.

Fixes: 2bcf4772e4 ("net: ethtool: try to protect all callback with netdev instance lock")
Signed-off-by: Stanislav Fomichev <sdf@fomichev.me>
Reviewed-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
Link: https://patch.msgid.link/20260414231035.1917035-1-sdf@fomichev.me
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2026-04-16 19:10:48 -07:00
..
conduit.c net: dsa: remove redundant netdev_lock_ops() from conduit ethtool ops 2026-04-16 19:10:48 -07:00
conduit.h net: dsa: Use conduit and user terms 2023-10-24 13:08:14 -07:00
devlink.c devlink: pass extack through to devlink_param::get() 2025-11-20 19:01:22 -08:00
devlink.h net: dsa: move rest of devlink setup/teardown to devlink.c 2022-11-22 20:41:47 -08:00
dsa.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
dsa.h net: dsa: Use conduit and user terms 2023-10-24 13:08:14 -07:00
Kconfig net: dsa: add tag format for MxL862xx switches 2026-02-11 11:27:57 +01:00
Makefile net: dsa: add tag format for MxL862xx switches 2026-02-11 11:27:57 +01:00
netlink.c net: dsa: Rename IFLA_DSA_MASTER to IFLA_DSA_CONDUIT 2023-10-24 13:08:14 -07:00
netlink.h net: dsa: kill off dsa_priv.h 2022-11-22 20:41:54 -08:00
port.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
port.h net: dsa: Use conduit and user terms 2023-10-24 13:08:14 -07:00
stubs.c net: dsa: replace NETDEV_PRE_CHANGE_HWTSTAMP notifier with a stub 2023-04-09 15:35:49 +01:00
switch.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
switch.h net: dsa: Use conduit and user terms 2023-10-24 13:08:14 -07:00
tag_8021q.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tag_8021q.h net: dsa: tag_sja1105: refactor skb->dev assignment to dsa_tag_8021q_find_user() 2024-07-15 06:55:15 -07:00
tag_ar9331.c net: fill in MODULE_DESCRIPTION()s for DSA tags 2024-01-05 08:06:19 -08:00
tag_brcm.c net: dsa: tag_brcm: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:39 -08:00
tag_dsa.c net: fill in MODULE_DESCRIPTION()s for DSA tags 2024-01-05 08:06:19 -08:00
tag_gswip.c net: dsa: tag_gswip: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:39 -08:00
tag_hellcreek.c net: dsa: tag_hellcreek: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:39 -08:00
tag_ksz.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tag_lan9303.c net: fill in MODULE_DESCRIPTION()s for DSA tags 2024-01-05 08:06:19 -08:00
tag_mtk.c net: dsa: tag_mtk: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:40 -08:00
tag_mxl-gsw1xx.c net: dsa: tag_mxl_gsw1xx: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:40 -08:00
tag_mxl862xx.c dsa: tag_mxl862xx: set dsa_default_offload_fwd_mark() 2026-04-06 18:30:33 -07:00
tag_none.c net: fill in MODULE_DESCRIPTION()s for DSA tags 2024-01-05 08:06:19 -08:00
tag_ocelot_8021q.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tag_ocelot.c net: dsa: tag_ocelot: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:40 -08:00
tag_qca.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tag_rtl4_a.c net: dsa: tag_rtl4_a: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:40 -08:00
tag_rtl8_4.c net: dsa: tag_rtl8_4: set KEEP flag 2026-04-12 09:03:55 -07:00
tag_rzn1_a5psw.c net: dsa: tag_rzn1_a5psw: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:41 -08:00
tag_sja1105.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
tag_trailer.c net: dsa: tag_trailer: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:41 -08:00
tag_vsc73xx_8021q.c net: dsa: vsc73xx: introduce tag 8021q for vsc73xx 2024-07-15 06:55:15 -07:00
tag_xrs700x.c net: dsa: tag_xrs700x: use the dsa_xmit_port_mask() helper 2025-11-28 20:03:41 -08:00
tag_yt921x.c net: dsa: tag_yt921x: add priority support 2026-02-03 15:09:31 +01:00
tag.c net: dsa: provide a software untagging function on RX for VLAN-aware bridges 2024-08-16 09:59:32 +01:00
tag.h net: dsa: introduce the dsa_xmit_port_mask() tagging protocol helper 2025-11-28 20:03:39 -08:00
trace.c net: dsa: add trace points for FDB/MDB operations 2023-04-12 08:36:07 +01:00
trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00
user.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
user.h net: dsa: update the unicast MAC address when changing conduit 2024-06-10 13:48:06 +01:00