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>
This commit is contained in:
Jiri Pirko
2010-02-23 23:17:07 +00:00
committed by David S. Miller
parent f9dcbcc9e3
commit 567ec874d1
18 changed files with 42 additions and 77 deletions

View File

@ -776,8 +776,9 @@ static void virtnet_set_rx_mode(struct net_device *dev)
mac_data->entries = mc_count;
addr = dev->mc_list;
for (i = 0; i < mc_count; i++, addr = addr->next)
memcpy(&mac_data->macs[i][0], addr->da_addr, ETH_ALEN);
i = 0;
netdev_for_each_mc_addr(addr, dev)
memcpy(&mac_data->macs[i++][0], addr->da_addr, ETH_ALEN);
sg_set_buf(&sg[1], mac_data,
sizeof(mac_data->entries) + (mc_count * ETH_ALEN));