diff options
author | Jiri Pirko <jpirko@redhat.com> | 2010-02-23 18:17:07 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-26 05:07:31 -0500 |
commit | 567ec874d15b478c8eda7e9a5d2dcb05f13f1fb5 (patch) | |
tree | e0c22740e44eca6f035e7dccbcff114a72d007a3 /drivers/net/virtio_net.c | |
parent | f9dcbcc9e338d08c0f7de7eba4eaafbbb7f81249 (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/virtio_net.c')
-rw-r--r-- | drivers/net/virtio_net.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index ce35b42cc2cb..e6095f3aa05f 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c | |||
@@ -776,8 +776,9 @@ static void virtnet_set_rx_mode(struct net_device *dev) | |||
776 | 776 | ||
777 | mac_data->entries = mc_count; | 777 | mac_data->entries = mc_count; |
778 | addr = dev->mc_list; | 778 | addr = dev->mc_list; |
779 | for (i = 0; i < mc_count; i++, addr = addr->next) | 779 | i = 0; |
780 | memcpy(&mac_data->macs[i][0], addr->da_addr, ETH_ALEN); | 780 | netdev_for_each_mc_addr(addr, dev) |
781 | memcpy(&mac_data->macs[i++][0], addr->da_addr, ETH_ALEN); | ||
781 | 782 | ||
782 | sg_set_buf(&sg[1], mac_data, | 783 | sg_set_buf(&sg[1], mac_data, |
783 | sizeof(mac_data->entries) + (mc_count * ETH_ALEN)); | 784 | sizeof(mac_data->entries) + (mc_count * ETH_ALEN)); |