Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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 <olteanv@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Vladimir Oltean and committed by
David S. Miller
864cd7b0 ec9121e7

+2 -2
+2 -2
drivers/net/dsa/b53/b53_common.c
··· 1286 1286 1287 1287 b53_read16(dev, B53_VLAN_PAGE, B53_VLAN_PORT_DEF_TAG(port), &pvid); 1288 1288 new_pvid = pvid; 1289 - if (dev->vlan_filtering_enabled && !vlan_filtering) { 1289 + if (!vlan_filtering) { 1290 1290 /* Filtering is currently enabled, use the default PVID since 1291 1291 * the bridge does not expect tagging anymore 1292 1292 */ 1293 1293 dev->ports[port].pvid = pvid; 1294 1294 new_pvid = b53_default_pvid(dev); 1295 - } else if (!dev->vlan_filtering_enabled && vlan_filtering) { 1295 + } else { 1296 1296 /* Filtering is currently disabled, restore the previous PVID */ 1297 1297 new_pvid = dev->ports[port].pvid; 1298 1298 }