diff options
Diffstat (limited to 'drivers/net/wireless/libertas_tf/main.c')
-rw-r--r-- | drivers/net/wireless/libertas_tf/main.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/net/wireless/libertas_tf/main.c b/drivers/net/wireless/libertas_tf/main.c index 895b557d664e..60787de56f3a 100644 --- a/drivers/net/wireless/libertas_tf/main.c +++ b/drivers/net/wireless/libertas_tf/main.c | |||
@@ -9,6 +9,8 @@ | |||
9 | */ | 9 | */ |
10 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | 10 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt |
11 | 11 | ||
12 | #include <linux/slab.h> | ||
13 | |||
12 | #include <linux/etherdevice.h> | 14 | #include <linux/etherdevice.h> |
13 | #include "libertas_tf.h" | 15 | #include "libertas_tf.h" |
14 | 16 | ||
@@ -417,22 +419,20 @@ static int lbtf_op_config(struct ieee80211_hw *hw, u32 changed) | |||
417 | } | 419 | } |
418 | 420 | ||
419 | static u64 lbtf_op_prepare_multicast(struct ieee80211_hw *hw, | 421 | static u64 lbtf_op_prepare_multicast(struct ieee80211_hw *hw, |
420 | int mc_count, struct dev_addr_list *mclist) | 422 | struct netdev_hw_addr_list *mc_list) |
421 | { | 423 | { |
422 | struct lbtf_private *priv = hw->priv; | 424 | struct lbtf_private *priv = hw->priv; |
423 | int i; | 425 | int i; |
426 | struct netdev_hw_addr *ha; | ||
427 | int mc_count = netdev_hw_addr_list_count(mc_list); | ||
424 | 428 | ||
425 | if (!mc_count || mc_count > MRVDRV_MAX_MULTICAST_LIST_SIZE) | 429 | if (!mc_count || mc_count > MRVDRV_MAX_MULTICAST_LIST_SIZE) |
426 | return mc_count; | 430 | return mc_count; |
427 | 431 | ||
428 | priv->nr_of_multicastmacaddr = mc_count; | 432 | priv->nr_of_multicastmacaddr = mc_count; |
429 | for (i = 0; i < mc_count; i++) { | 433 | i = 0; |
430 | if (!mclist) | 434 | netdev_hw_addr_list_for_each(ha, mc_list) |
431 | break; | 435 | memcpy(&priv->multicastlist[i++], ha->addr, ETH_ALEN); |
432 | memcpy(&priv->multicastlist[i], mclist->da_addr, | ||
433 | ETH_ALEN); | ||
434 | mclist = mclist->next; | ||
435 | } | ||
436 | 436 | ||
437 | return mc_count; | 437 | return mc_count; |
438 | } | 438 | } |