Commit 25a1729e authored by Florian Fainelli's avatar Florian Fainelli Committed by Greg Kroah-Hartman

net: dsa: b53: Always use dev->vlan_enabled in b53_configure_vlan()

[ Upstream commit df373702 ]

b53_configure_vlan() is called by the bcm_sf2 driver upon setup and
indirectly through resume as well. During the initial setup, we are
guaranteed that dev->vlan_enabled is false, so there is no change in
behavior, however during suspend, we may have enabled VLANs before, so we
do want to restore that setting.

Fixes: dad8d7c6 ("net: dsa: b53: Properly account for VLAN filtering")
Fixes: 967dd82f ("net: dsa: b53: Add support for Broadcom RoboSwitch")
Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 62e5f512
...@@ -655,7 +655,7 @@ int b53_configure_vlan(struct dsa_switch *ds) ...@@ -655,7 +655,7 @@ int b53_configure_vlan(struct dsa_switch *ds)
b53_do_vlan_op(dev, VTA_CMD_CLEAR); b53_do_vlan_op(dev, VTA_CMD_CLEAR);
} }
b53_enable_vlan(dev, false, dev->vlan_filtering_enabled); b53_enable_vlan(dev, dev->vlan_enabled, dev->vlan_filtering_enabled);
b53_for_each_port(dev, i) b53_for_each_port(dev, i)
b53_write16(dev, B53_VLAN_PAGE, b53_write16(dev, B53_VLAN_PAGE,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment