summaryrefslogtreecommitdiff
path: root/drivers/net/sungem.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/sungem.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/sungem.c')
-rw-r--r--drivers/net/sungem.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/net/sungem.c b/drivers/net/sungem.c
index d497ec053953..4344017bfaef 100644
--- a/drivers/net/sungem.c
+++ b/drivers/net/sungem.c
@@ -1846,17 +1846,13 @@ static u32 gem_setup_multicast(struct gem *gp)
} else {
u16 hash_table[16];
u32 crc;
- struct dev_mc_list *dmi = gp->dev->mc_list;
+ struct dev_mc_list *dmi;
int i;
- for (i = 0; i < 16; i++)
- hash_table[i] = 0;
-
- for (i = 0; i < netdev_mc_count(gp->dev); i++) {
+ memset(hash_table, 0, sizeof(hash_table));
+ netdev_for_each_mc_addr(dmi, gp->dev) {
char *addrs = dmi->dmi_addr;
- dmi = dmi->next;
-
if (!(*addrs & 1))
continue;