]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: use switchdev_handle_fdb_{add,del}_to_device
authorVladimir Oltean <vladimir.oltean@nxp.com>
Mon, 19 Jul 2021 13:51:40 +0000 (16:51 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 20 Jul 2021 14:04:27 +0000 (07:04 -0700)
commit6a321f91d12e9f84613bb8a1946fff8f4868c94a
tree9f839966890a4400be58605618b5d98bd36a1be6
parentabc6d3f1b335970531f8751e824ad26e4e0417a5
net: dsa: use switchdev_handle_fdb_{add,del}_to_device

Using the new fan-out helper for FDB entries installed on the software
bridge, we can install host addresses with the proper refcount on the
CPU port, such that this case:

ip link set swp0 master br0
ip link set swp1 master br0
ip link set swp2 master br0
ip link set swp3 master br0
ip link set br0 address 00:01:02:03:04:05
ip link set swp3 nomaster

works properly and the br0 address remains installed as a host entry
with refcount 3 instead of getting deleted.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dsa/dsa_priv.h
net/dsa/slave.c