Skip to content

Commit 626a832

Browse files
vladimirolteandavem330
authored andcommitted
net: dsa: felix: accept VLAN config regardless of bridge VLAN awareness state
The ocelot core library is written with the idea in mind that the VLAN table is populated by the bridge. Otherwise, not even a sane default pvid is provided: in standalone mode, the default pvid is 0, and the core expects the bridge layer to change it to 1. So without this patch, the VLAN table is completely empty at the end of the commands below, and traffic is broken as a result: ip link add dev br0 type bridge vlan_filtering 0 && ip link set dev br0 up for eth in $(ls /sys/bus/pci/devices/0000\:00\:00.5/net/); do ip link set dev $eth master br0 ip link set dev $eth up done ip link set dev br0 type bridge vlan_filtering 1 Signed-off-by: Vladimir Oltean <[email protected]> Reviewed-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 5a1b72c commit 626a832

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/net/dsa/ocelot/felix.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -594,6 +594,7 @@ static int felix_setup(struct dsa_switch *ds)
594594
ANA_FLOODING, tc);
595595

596596
ds->mtu_enforcement_ingress = true;
597+
ds->configure_vlan_while_not_filtering = true;
597598
/* It looks like the MAC/PCS interrupt register - PM0_IEVENT (0x8040)
598599
* isn't instantiated for the Felix PF.
599600
* In-band AN may take a few ms to complete, so we need to poll.

0 commit comments

Comments
 (0)