Commit afe0159d authored by stephen hemminger's avatar stephen hemminger Committed by David S. Miller

bridge: multicast_flood cleanup

Move some declarations around to make it clearer which variables
are being used inside loop.
Signed-off-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 83f6a740
...@@ -208,17 +208,15 @@ static void br_multicast_flood(struct net_bridge_mdb_entry *mdst, ...@@ -208,17 +208,15 @@ static void br_multicast_flood(struct net_bridge_mdb_entry *mdst,
{ {
struct net_device *dev = BR_INPUT_SKB_CB(skb)->brdev; struct net_device *dev = BR_INPUT_SKB_CB(skb)->brdev;
struct net_bridge *br = netdev_priv(dev); struct net_bridge *br = netdev_priv(dev);
struct net_bridge_port *port; struct net_bridge_port *prev = NULL;
struct net_bridge_port *lport, *rport;
struct net_bridge_port *prev;
struct net_bridge_port_group *p; struct net_bridge_port_group *p;
struct hlist_node *rp; struct hlist_node *rp;
prev = NULL;
rp = rcu_dereference(br->router_list.first); rp = rcu_dereference(br->router_list.first);
p = mdst ? rcu_dereference(mdst->ports) : NULL; p = mdst ? rcu_dereference(mdst->ports) : NULL;
while (p || rp) { while (p || rp) {
struct net_bridge_port *port, *lport, *rport;
lport = p ? p->port : NULL; lport = p ? p->port : NULL;
rport = rp ? hlist_entry(rp, struct net_bridge_port, rlist) : rport = rp ? hlist_entry(rp, struct net_bridge_port, rlist) :
NULL; NULL;
......
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