aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/vmxnet3
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2010-02-23 18:17:07 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-26 05:07:31 -0500
commit567ec874d15b478c8eda7e9a5d2dcb05f13f1fb5 (patch)
treee0c22740e44eca6f035e7dccbcff114a72d007a3 /drivers/net/vmxnet3
parentf9dcbcc9e338d08c0f7de7eba4eaafbbb7f81249 (diff)
net: convert multiple drivers to use netdev_for_each_mc_addr, part6
Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/vmxnet3')
-rw-r--r--drivers/net/vmxnet3/vmxnet3_drv.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/vmxnet3/vmxnet3_drv.c b/drivers/net/vmxnet3/vmxnet3_drv.c
index ee1b397417f3..cff3485d9673 100644
--- a/drivers/net/vmxnet3/vmxnet3_drv.c
+++ b/drivers/net/vmxnet3/vmxnet3_drv.c
@@ -1675,15 +1675,12 @@ vmxnet3_copy_mc(struct net_device *netdev)
1675 /* We may be called with BH disabled */ 1675 /* We may be called with BH disabled */
1676 buf = kmalloc(sz, GFP_ATOMIC); 1676 buf = kmalloc(sz, GFP_ATOMIC);
1677 if (buf) { 1677 if (buf) {
1678 int i; 1678 struct dev_mc_list *mc;
1679 struct dev_mc_list *mc = netdev->mc_list; 1679 int i = 0;
1680 1680
1681 for (i = 0; i < netdev_mc_count(netdev); i++) { 1681 netdev_for_each_mc_addr(mc, netdev)
1682 BUG_ON(!mc); 1682 memcpy(buf + i++ * ETH_ALEN, mc->dmi_addr,
1683 memcpy(buf + i * ETH_ALEN, mc->dmi_addr,
1684 ETH_ALEN); 1683 ETH_ALEN);
1685 mc = mc->next;
1686 }
1687 } 1684 }
1688 } 1685 }
1689 return buf; 1686 return buf;