bridge: vlan: drop unnecessary flush code
authorNikolay Aleksandrov <nikolay@cumulusnetworks.com>
Mon, 12 Oct 2015 19:47:04 +0000 (21:47 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 13 Oct 2015 11:57:56 +0000 (04:57 -0700)
As Ido Schimmel pointed out the vlan_vid_del() code in nbp_vlan_flush is
unnecessary (and is actually a remnant of the old vlan code) so we can
remove it.

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/bridge/br_vlan.c

index ffaa6d986505c941d2b4690b976bccf66b01cb6c..85e67568092e8bea0123892ac8c7203f4fa04a7b 100644 (file)
@@ -959,14 +959,7 @@ int nbp_vlan_delete(struct net_bridge_port *port, u16 vid)
 
 void nbp_vlan_flush(struct net_bridge_port *port)
 {
-       struct net_bridge_vlan_group *vg;
-       struct net_bridge_vlan *vlan;
-
        ASSERT_RTNL();
 
-       vg = nbp_vlan_group(port);
-       list_for_each_entry(vlan, &vg->vlan_list, vlist)
-               vlan_vid_del(port->dev, port->br->vlan_proto, vlan->vid);
-
-       __vlan_flush(vg);
+       __vlan_flush(nbp_vlan_group(port));
 }