summaryrefslogtreecommitdiff
path: root/drivers/net/smsc9420.c
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2010-02-18 00:42:54 +0000
committerDavid S. Miller <davem@davemloft.net>2010-02-18 14:47:49 -0800
commit5508590c193661bc1484ad7b952af5fceacea40d (patch)
tree8b7d1655f63034725127b9456afa5bad4bb6e83a /drivers/net/smsc9420.c
parent2a0d18f97cc15d57ad0c93259a3df4cb72c5a28b (diff)
net: convert multiple drivers to use netdev_for_each_mc_addr, part2
Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/smsc9420.c')
-rw-r--r--drivers/net/smsc9420.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/smsc9420.c b/drivers/net/smsc9420.c
index 2bd3c986559a..30110a11d737 100644
--- a/drivers/net/smsc9420.c
+++ b/drivers/net/smsc9420.c
@@ -1063,11 +1063,11 @@ static void smsc9420_set_multicast_list(struct net_device *dev)
mac_cr |= MAC_CR_MCPAS_;
mac_cr &= (~MAC_CR_HPFILT_);
} else if (!netdev_mc_empty(dev)) {
- struct dev_mc_list *mc_list = dev->mc_list;
+ struct dev_mc_list *mc_list;
u32 hash_lo = 0, hash_hi = 0;
smsc_dbg(HW, "Multicast filter enabled");
- while (mc_list) {
+ netdev_for_each_mc_addr(mc_list, dev) {
u32 bit_num = smsc9420_hash(mc_list->dmi_addr);
u32 mask = 1 << (bit_num & 0x1F);
@@ -1076,7 +1076,6 @@ static void smsc9420_set_multicast_list(struct net_device *dev)
else
hash_lo |= mask;
- mc_list = mc_list->next;
}
smsc9420_reg_write(pd, HASHH, hash_hi);
smsc9420_reg_write(pd, HASHL, hash_lo);