Skip to content

Commit

Permalink
net: dsa: ocelot: request DSA to fix up lack of address learning on C…
Browse files Browse the repository at this point in the history
…PU port

Given the following setup:

ip link add br0 type bridge
ip link set eno0 master br0
ip link set swp0 master br0
ip link set swp1 master br0
ip link set swp2 master br0
ip link set swp3 master br0

Currently, packets received on a DSA slave interface (such as swp0)
which should be routed by the software bridge towards a non-switch port
(such as eno0) are also flooded towards the other switch ports (swp1,
swp2, swp3) because the destination is unknown to the hardware switch.

This patch addresses the issue by monitoring the addresses learnt by the
software bridge on eno0, and adding/deleting them as static FDB entries
on the CPU port accordingly.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Vladimir Oltean authored and Jakub Kicinski committed Jan 7, 2021
1 parent d5f1948 commit c54913c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/net/dsa/ocelot/felix.c
Original file line number Diff line number Diff line change
Expand Up @@ -629,6 +629,7 @@ static int felix_setup(struct dsa_switch *ds)

ds->mtu_enforcement_ingress = true;
ds->configure_vlan_while_not_filtering = true;
ds->assisted_learning_on_cpu_port = true;

return 0;
}
Expand Down

0 comments on commit c54913c

Please sign in to comment.