linux/drivers/net/dsa
Tobias Waldekranz 16e056beca net: dsa: mv88e6xxx: Avoid VTU corruption on 6097
[ Upstream commit 92307069a9 ]

As soon as you add the second port to a VLAN, all other port
membership configuration is overwritten with zeroes. The HW interprets
this as all ports being "unmodified members" of the VLAN.

In the simple case when all ports belong to the same VLAN, switching
will still work. But using multiple VLANs or trying to set multiple
ports as tagged members will not work.

On the 6352, doing a VTU GetNext op, followed by an STU GetNext op
will leave you with both the member- and state- data in the VTU/STU
data registers. But on the 6097 (which uses the same implementation),
the STU GetNext will override the information gathered from the VTU
GetNext.

Separate the two stages, parsing the result of the VTU GetNext before
doing the STU GetNext.

We opt to update the existing implementation for all applicable chips,
as opposed to creating a separate callback for 6097, because although
the previous implementation did work for (at least) 6352, the
datasheet does not mention the masking behavior.

Fixes: ef6fcea37f ("net: dsa: mv88e6xxx: get STU entry on VTU GetNext")
Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
Link: https://lore.kernel.org/r/20201112114335.27371-1-tobias@waldekranz.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-11-24 13:27:17 +01:00
..
b53 net: dsa: b53: check for timeout 2020-08-26 10:31:06 +02:00
microchip net: dsa: microchip: initialize mutex before use 2018-11-23 08:17:06 +01:00
mv88e6xxx net: dsa: mv88e6xxx: Avoid VTU corruption on 6097 2020-11-24 13:27:17 +01:00
bcm_sf2_cfp.c net: dsa: bcm_sf2: Fix overflow checks 2020-04-23 10:30:22 +02:00
bcm_sf2_regs.h net: dsa: bcm_sf2: Disable learning while in WoL 2018-08-03 12:11:43 -07:00
bcm_sf2.c net: dsa: bcm_sf2: Fix node reference count 2020-07-22 09:32:03 +02:00
bcm_sf2.h
dsa_loop_bdinfo.c
dsa_loop.c net: dsa: loop: Add module soft dependency 2020-05-20 08:18:37 +02:00
dsa_loop.h
Kconfig net: dsa: LAN9303: select REGMAP when LAN9303 enable 2019-12-31 16:35:29 +01:00
lan9303_i2c.c net: dsa: lan9303: Adjust indenting 2017-11-08 13:29:06 +09:00
lan9303_mdio.c net: dsa: lan9303: Adjust indenting 2017-11-08 13:29:06 +09:00
lan9303-core.c net: dsa: Pass stringset to ethtool operations 2018-04-27 11:53:03 -04:00
lan9303.h
Makefile net: dsa: realtek-smi: Add Realtek SMI driver 2018-07-18 13:43:38 +09:00
mt7530.c net: dsa: mt7530: set CPU port to fallback mode 2020-06-07 13:17:54 +02:00
mt7530.h net: dsa: mt7530: set CPU port to fallback mode 2020-06-07 13:17:54 +02:00
mv88e6060.c mv88e6060: disable hardware level MAC learning 2018-12-21 14:15:20 +01:00
mv88e6060.h
qca8k.c net: dsa: qca8k: Enable delay for RGMII_ID mode 2020-01-27 14:50:25 +01:00
qca8k.h net: dsa: qca8k: Enable delay for RGMII_ID mode 2020-01-27 14:50:25 +01:00
realtek-smi.c net: dsa: realtek-smi: fix OF child-node lookup 2019-01-22 21:40:34 +01:00
realtek-smi.h net: dsa: rtl8366: Refactor VLAN/PVID init 2020-10-29 09:55:10 +01:00
rtl8366.c net: dsa: rtl8366: Skip PVID setting if not requested 2020-10-29 09:55:11 +01:00
rtl8366rb.c net: dsa: rtl8366rb: Support all 4096 VLANs 2020-10-29 09:55:11 +01:00
vitesse-vsc73xx.c net: dsa: vsc73xx: Make some functions static 2018-07-05 19:29:29 +09:00