Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 61204
b: refs/heads/master
c: 26cc252
h: refs/heads/master
v: v3
  • Loading branch information
Denis Cheng authored and David S. Miller committed Jul 18, 2007
1 parent 25e00b8 commit 0c787a3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 13 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 456ad75c89cdb72e11dcdb6b0794802a6f50c8a3
refs/heads/master: 26cc2522cb6ebf0c1c736485e102e9654cde1145
16 changes: 4 additions & 12 deletions trunk/net/core/dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -2777,23 +2777,16 @@ int dev_unicast_add(struct net_device *dev, void *addr, int alen)
}
EXPORT_SYMBOL(dev_unicast_add);

static void dev_unicast_discard(struct net_device *dev)
static void dev_addr_discard(struct net_device *dev)
{
netif_tx_lock_bh(dev);

__dev_addr_discard(&dev->uc_list);
dev->uc_count = 0;
netif_tx_unlock_bh(dev);
}

/*
* Discard multicast list when a device is downed
*/

static 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);
}

Expand Down Expand Up @@ -3751,8 +3744,7 @@ void unregister_netdevice(struct net_device *dev)
/*
* Flush the unicast and multicast chains
*/
dev_unicast_discard(dev);
dev_mc_discard(dev);
dev_addr_discard(dev);

if (dev->uninit)
dev->uninit(dev);
Expand Down

0 comments on commit 0c787a3

Please sign in to comment.