summaryrefslogtreecommitdiff
path: root/net/bridge/br_if.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-10-24 18:18:09 -0400
committerDavid S. Miller <davem@davemloft.net>2011-10-24 18:18:09 -0400
commit1805b2f04855f07afe3a71d620a68f483b0ed74f (patch)
treeb823b90f37f5404fcaef70f785c70112ca74a329 /net/bridge/br_if.c
parent78d81d15b74246c7cedf84894434890b33da3907 (diff)
parentf42af6c486aa5ca6ee62800cb45c5b252020509d (diff)
downloadlinux-rpi3-1805b2f04855f07afe3a71d620a68f483b0ed74f.tar.gz
linux-rpi3-1805b2f04855f07afe3a71d620a68f483b0ed74f.tar.bz2
linux-rpi3-1805b2f04855f07afe3a71d620a68f483b0ed74f.zip
Merge branch 'master' of ra.kernel.org:/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'net/bridge/br_if.c')
-rw-r--r--net/bridge/br_if.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/net/bridge/br_if.c b/net/bridge/br_if.c
index c3b77dceb937..f603e5b0b930 100644
--- a/net/bridge/br_if.c
+++ b/net/bridge/br_if.c
@@ -160,9 +160,10 @@ static void del_nbp(struct net_bridge_port *p)
call_rcu(&p->rcu, destroy_nbp_rcu);
}
-/* called with RTNL */
-static void del_br(struct net_bridge *br, struct list_head *head)
+/* Delete bridge device */
+void br_dev_delete(struct net_device *dev, struct list_head *head)
{
+ struct net_bridge *br = netdev_priv(dev);
struct net_bridge_port *p, *n;
list_for_each_entry_safe(p, n, &br->port_list, list) {
@@ -267,7 +268,7 @@ int br_del_bridge(struct net *net, const char *name)
}
else
- del_br(netdev_priv(dev), NULL);
+ br_dev_delete(dev, NULL);
rtnl_unlock();
return ret;
@@ -446,7 +447,7 @@ void __net_exit br_net_exit(struct net *net)
rtnl_lock();
for_each_netdev(net, dev)
if (dev->priv_flags & IFF_EBRIDGE)
- del_br(netdev_priv(dev), &list);
+ br_dev_delete(dev, &list);
unregister_netdevice_many(&list);
rtnl_unlock();