diff options
author | Vladimir Oltean <vladimir.oltean@nxp.com> | 2022-02-15 19:02:13 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-02-16 11:21:04 +0000 |
commit | 263029ae317298a3719d2cd88a818c3a29a80e15 (patch) | |
tree | 38587ef3cd43ba31f241f9d23e855770c8be2421 /net | |
parent | 8d23a54f5beea59b560855fb571e5d73d783e0b4 (diff) |
net: bridge: make nbp_switchdev_unsync_objs() follow reverse order of sync()
There may be switchdev drivers that can add/remove a FDB or MDB entry
only as long as the VLAN it's in has been notified and offloaded first.
The nbp_switchdev_sync_objs() method satisfies this requirement on
addition, but nbp_switchdev_unsync_objs() first deletes VLANs, then
deletes MDBs and FDBs. Reverse the order of the function calls to cater
to this requirement.
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/bridge/br_switchdev.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/bridge/br_switchdev.c b/net/bridge/br_switchdev.c index fb5115387d82..b7c13f8cfce5 100644 --- a/net/bridge/br_switchdev.c +++ b/net/bridge/br_switchdev.c @@ -707,11 +707,11 @@ static void nbp_switchdev_unsync_objs(struct net_bridge_port *p, struct net_device *br_dev = p->br->dev; struct net_device *dev = p->dev; - br_switchdev_vlan_replay(br_dev, dev, ctx, false, blocking_nb, NULL); + br_switchdev_fdb_replay(br_dev, ctx, false, atomic_nb); br_switchdev_mdb_replay(br_dev, dev, ctx, false, blocking_nb, NULL); - br_switchdev_fdb_replay(br_dev, ctx, false, atomic_nb); + br_switchdev_vlan_replay(br_dev, dev, ctx, false, blocking_nb, NULL); } /* Let the bridge know that this port is offloaded, so that it can assign a |