From 48e2f183cb1709600012265a2e723f45a350d5fe Mon Sep 17 00:00:00 2001 From: Jiri Pirko Date: Mon, 22 Feb 2010 09:22:26 +0000 Subject: net: convert multiple drivers to use netdev_for_each_mc_addr, part4 Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller --- drivers/net/hp100.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'drivers/net/hp100.c') diff --git a/drivers/net/hp100.c b/drivers/net/hp100.c index debac1bc6799..b766a69bf0ca 100644 --- a/drivers/net/hp100.c +++ b/drivers/net/hp100.c @@ -2098,7 +2098,7 @@ static void hp100_set_multicast_list(struct net_device *dev) /* set hash filter to receive all multicast packets */ memset(&lp->hash_bytes, 0xff, 8); } else { - int i, j, idx; + int i, idx; u_char *addrs; struct dev_mc_list *dmi; @@ -2107,14 +2107,14 @@ static void hp100_set_multicast_list(struct net_device *dev) printk("hp100: %s: computing hash filter - mc_count = %i\n", dev->name, netdev_mc_count(dev)); #endif - for (i = 0, dmi = dev->mc_list; i < netdev_mc_count(dev); i++, dmi = dmi->next) { + netdev_for_each_mc_addr(dmi, dev) { addrs = dmi->dmi_addr; if ((*addrs & 0x01) == 0x01) { /* multicast address? */ #ifdef HP100_DEBUG printk("hp100: %s: multicast = %pM, ", dev->name, addrs); #endif - for (j = idx = 0; j < 6; j++) { + for (i = idx = 0; i < 6; i++) { idx ^= *addrs++ & 0x3f; printk(":%02x:", idx); } -- cgit v1.2.3-58-ga151