linux/net/dsa
Russell King (Oracle) 145622771d net: dsa: mark parsed interface mode for legacy switch drivers
If we successfully parsed an interface mode with a legacy switch
driver, populate that mode into phylink's supported interfaces rather
than defaulting to the internal and gmii interfaces.

This hasn't caused an issue so far, because when the interface doesn't
match a supported one, phylink_validate() doesn't clear the supported
mask, but instead returns -EINVAL. phylink_parse_fixedlink() doesn't
check this return value, and merely relies on the supported ethtool
link modes mask being cleared. Therefore, the fixed link settings end
up being allowed despite validation failing.

Before this causes a problem, arrange for DSA to more accurately
populate phylink's supported interfaces mask so validation can
correctly succeed.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
Link: https://lore.kernel.org/r/E1qTKdM-003Cpx-Eh@rmk-PC.armlinux.org.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2023-08-09 13:08:09 -07:00
..
devlink.c
devlink.h
dsa.c net: dsa: avoid suspicious RCU usage for synced VLAN-aware MAC addresses 2023-06-27 09:37:41 -07:00
dsa.h
Kconfig
Makefile
master.c
master.h
netlink.c
netlink.h
port.c net: dsa: mark parsed interface mode for legacy switch drivers 2023-08-09 13:08:09 -07:00
port.h
slave.c net: dsa: remove deprecated strncpy 2023-07-23 11:45:46 +01:00
slave.h
stubs.c
switch.c net: dsa: avoid suspicious RCU usage for synced VLAN-aware MAC addresses 2023-06-27 09:37:41 -07:00
switch.h net: dsa: avoid suspicious RCU usage for synced VLAN-aware MAC addresses 2023-06-27 09:37:41 -07:00
tag_8021q.c net: dsa: update TX path comments to not mention skb_mac_header() 2023-04-23 14:16:45 +01:00
tag_8021q.h
tag_ar9331.c
tag_brcm.c
tag_dsa.c
tag_gswip.c
tag_hellcreek.c
tag_ksz.c
tag_lan9303.c
tag_mtk.c
tag_none.c
tag_ocelot_8021q.c
tag_ocelot.c net: dsa: tag_ocelot: call only the relevant portion of __skb_vlan_pop() on TX 2023-04-23 14:16:45 +01:00
tag_qca.c net: dsa: tag_qca: return early if dev is not found 2023-08-01 12:02:42 +02:00
tag_rtl4_a.c
tag_rtl8_4.c
tag_rzn1_a5psw.c
tag_sja1105.c net: dsa: sja1105: always enable the send_meta options 2023-07-04 19:42:27 +01:00
tag_trailer.c
tag_xrs700x.c
tag.c
tag.h net: dsa: update TX path comments to not mention skb_mac_header() 2023-04-23 14:16:45 +01:00
trace.c
trace.h