aboutsummaryrefslogtreecommitdiff
path: root/net/core/dev_mcast.c
diff options
context:
space:
mode:
authorDenis Cheng <crquan@gmail.com>2007-07-18 02:10:54 -0700
committerDavid S. Miller <davem@davemloft.net>2007-07-18 02:10:54 -0700
commit456ad75c89cdb72e11dcdb6b0794802a6f50c8a3 (patch)
tree0e220771195438b704985418e47a7dc29d9a7d7b /net/core/dev_mcast.c
parenteb4965344965530411359891214cd6fcab483649 (diff)
[NET]: move dev_mc_discard from dev_mcast.c to dev.c
Because this function is only called by unregister_netdevice, this moving could make this non-global function static, and also remove its declaration in netdevice.h; Any further, function __dev_addr_discard is also just called by dev_mc_discard and dev_unicast_discard, keeping this two functions both in one c file could make __dev_addr_discard also static and remove its declaration in netdevice.h; Futhermore, the sequential call to dev_unicast_discard and then dev_mc_discard in unregister_netdevice have a similar mechanism that: (netif_tx_lock_bh / __dev_addr_discard / netif_tx_unlock_bh), they should merged into one to eliminate duplicates in acquiring and releasing the dev->_xmit_lock, this would be done in my following patch. Signed-off-by: Denis Cheng <crquan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/dev_mcast.c')
-rw-r--r--net/core/dev_mcast.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/net/core/dev_mcast.c b/net/core/dev_mcast.c
index 235a2a8a0d0..99aece1aecc 100644
--- a/net/core/dev_mcast.c
+++ b/net/core/dev_mcast.c
@@ -177,18 +177,6 @@ void dev_mc_unsync(struct net_device *to, struct net_device *from)
}
EXPORT_SYMBOL(dev_mc_unsync);
-/*
- * Discard multicast list when a device is downed
- */
-
-void dev_mc_discard(struct net_device *dev)
-{
- netif_tx_lock_bh(dev);
- __dev_addr_discard(&dev->mc_list);
- dev->mc_count = 0;
- netif_tx_unlock_bh(dev);
-}
-
#ifdef CONFIG_PROC_FS
static void *dev_mc_seq_start(struct seq_file *seq, loff_t *pos)
{