diff options
author | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-05-30 19:16:45 -0400 |
---|---|---|
committer | Andrea Bastoni <bastoni@cs.unc.edu> | 2010-05-30 19:16:45 -0400 |
commit | ada47b5fe13d89735805b566185f4885f5a3f750 (patch) | |
tree | 644b88f8a71896307d71438e9b3af49126ffb22b /net/bluetooth/bnep/netdev.c | |
parent | 43e98717ad40a4ae64545b5ba047c7b86aa44f4f (diff) | |
parent | 3280f21d43ee541f97f8cda5792150d2dbec20d5 (diff) |
Merge branch 'wip-2.6.34' into old-private-masterarchived-private-master
Diffstat (limited to 'net/bluetooth/bnep/netdev.c')
-rw-r--r-- | net/bluetooth/bnep/netdev.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/net/bluetooth/bnep/netdev.c b/net/bluetooth/bnep/netdev.c index 26fb831ef7e0..5643a2391e76 100644 --- a/net/bluetooth/bnep/netdev.c +++ b/net/bluetooth/bnep/netdev.c | |||
@@ -26,6 +26,7 @@ | |||
26 | */ | 26 | */ |
27 | 27 | ||
28 | #include <linux/module.h> | 28 | #include <linux/module.h> |
29 | #include <linux/slab.h> | ||
29 | 30 | ||
30 | #include <linux/socket.h> | 31 | #include <linux/socket.h> |
31 | #include <linux/netdevice.h> | 32 | #include <linux/netdevice.h> |
@@ -64,7 +65,7 @@ static void bnep_net_set_mc_list(struct net_device *dev) | |||
64 | struct sk_buff *skb; | 65 | struct sk_buff *skb; |
65 | int size; | 66 | int size; |
66 | 67 | ||
67 | BT_DBG("%s mc_count %d", dev->name, dev->mc_count); | 68 | BT_DBG("%s mc_count %d", dev->name, netdev_mc_count(dev)); |
68 | 69 | ||
69 | size = sizeof(*r) + (BNEP_MAX_MULTICAST_FILTERS + 1) * ETH_ALEN * 2; | 70 | size = sizeof(*r) + (BNEP_MAX_MULTICAST_FILTERS + 1) * ETH_ALEN * 2; |
70 | skb = alloc_skb(size, GFP_ATOMIC); | 71 | skb = alloc_skb(size, GFP_ATOMIC); |
@@ -97,7 +98,9 @@ static void bnep_net_set_mc_list(struct net_device *dev) | |||
97 | 98 | ||
98 | /* FIXME: We should group addresses here. */ | 99 | /* FIXME: We should group addresses here. */ |
99 | 100 | ||
100 | for (i = 0; i < dev->mc_count && i < BNEP_MAX_MULTICAST_FILTERS; i++) { | 101 | for (i = 0; |
102 | i < netdev_mc_count(dev) && i < BNEP_MAX_MULTICAST_FILTERS; | ||
103 | i++) { | ||
101 | memcpy(__skb_put(skb, ETH_ALEN), dmi->dmi_addr, ETH_ALEN); | 104 | memcpy(__skb_put(skb, ETH_ALEN), dmi->dmi_addr, ETH_ALEN); |
102 | memcpy(__skb_put(skb, ETH_ALEN), dmi->dmi_addr, ETH_ALEN); | 105 | memcpy(__skb_put(skb, ETH_ALEN), dmi->dmi_addr, ETH_ALEN); |
103 | dmi = dmi->next; | 106 | dmi = dmi->next; |