Skip to content

Commit 864cd7b

Browse files
vladimirolteandavem330
authored andcommitted
net: dsa: b53: Let DSA call .port_vlan_filtering only when necessary
Since DSA has recently learned to treat better with drivers that set vlan_filtering_is_global, doing this is no longer required. Signed-off-by: Vladimir Oltean <[email protected]> Reviewed-by: Andrew Lunn <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent ec9121e commit 864cd7b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/net/dsa/b53/b53_common.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,13 +1286,13 @@ int b53_vlan_filtering(struct dsa_switch *ds, int port, bool vlan_filtering)
12861286

12871287
b53_read16(dev, B53_VLAN_PAGE, B53_VLAN_PORT_DEF_TAG(port), &pvid);
12881288
new_pvid = pvid;
1289-
if (dev->vlan_filtering_enabled && !vlan_filtering) {
1289+
if (!vlan_filtering) {
12901290
/* Filtering is currently enabled, use the default PVID since
12911291
* the bridge does not expect tagging anymore
12921292
*/
12931293
dev->ports[port].pvid = pvid;
12941294
new_pvid = b53_default_pvid(dev);
1295-
} else if (!dev->vlan_filtering_enabled && vlan_filtering) {
1295+
} else {
12961296
/* Filtering is currently disabled, restore the previous PVID */
12971297
new_pvid = dev->ports[port].pvid;
12981298
}

0 commit comments

Comments
 (0)