aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorDenis Cheng <crquan@gmail.com>2007-07-18 05:12:56 -0400
committerDavid S. Miller <davem@davemloft.net>2007-07-18 05:12:56 -0400
commit12972621c8a18465e3d20cc8e3006a8b7f7788df (patch)
treea2ab067958ee6b7bfae0a625514aff96d903be18 /net
parent26cc2522cb6ebf0c1c736485e102e9654cde1145 (diff)
[NET]: move __dev_addr_discard adjacent to dev_addr_discard for readability
Signed-off-by: Denis Cheng <crquan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/core/dev.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index 17c9cbd77eb0..6357f54c8ff7 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2715,20 +2715,6 @@ int __dev_addr_add(struct dev_addr_list **list, int *count,
2715 return 0; 2715 return 0;
2716} 2716}
2717 2717
2718static void __dev_addr_discard(struct dev_addr_list **list)
2719{
2720 struct dev_addr_list *tmp;
2721
2722 while (*list != NULL) {
2723 tmp = *list;
2724 *list = tmp->next;
2725 if (tmp->da_users > tmp->da_gusers)
2726 printk("__dev_addr_discard: address leakage! "
2727 "da_users=%d\n", tmp->da_users);
2728 kfree(tmp);
2729 }
2730}
2731
2732/** 2718/**
2733 * dev_unicast_delete - Release secondary unicast address. 2719 * dev_unicast_delete - Release secondary unicast address.
2734 * @dev: device 2720 * @dev: device
@@ -2777,6 +2763,20 @@ int dev_unicast_add(struct net_device *dev, void *addr, int alen)
2777} 2763}
2778EXPORT_SYMBOL(dev_unicast_add); 2764EXPORT_SYMBOL(dev_unicast_add);
2779 2765
2766static void __dev_addr_discard(struct dev_addr_list **list)
2767{
2768 struct dev_addr_list *tmp;
2769
2770 while (*list != NULL) {
2771 tmp = *list;
2772 *list = tmp->next;
2773 if (tmp->da_users > tmp->da_gusers)
2774 printk("__dev_addr_discard: address leakage! "
2775 "da_users=%d\n", tmp->da_users);
2776 kfree(tmp);
2777 }
2778}
2779
2780static void dev_addr_discard(struct net_device *dev) 2780static void dev_addr_discard(struct net_device *dev)
2781{ 2781{
2782 netif_tx_lock_bh(dev); 2782 netif_tx_lock_bh(dev);