summaryrefslogtreecommitdiff
path: root/drivers/net/cpmac.c
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2010-02-17 11:09:31 +0000
committerDavid S. Miller <davem@davemloft.net>2010-02-17 13:27:12 -0800
commite1d444771e0895c7706bc99857d69e4f2a58a531 (patch)
treeb17410e94c6c78416b6e125fad0c4ed208edc39f /drivers/net/cpmac.c
parentd7b855c2dcc89587f36338bd383203322efb9903 (diff)
net: convert multiple drivers to use netdev_for_each_mc_addr
Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cpmac.c')
-rw-r--r--drivers/net/cpmac.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/cpmac.c b/drivers/net/cpmac.c
index c9c537be4ab..0074f3bf17b 100644
--- a/drivers/net/cpmac.c
+++ b/drivers/net/cpmac.c
@@ -320,7 +320,6 @@ static int cpmac_config(struct net_device *dev, struct ifmap *map)
static void cpmac_set_multicast_list(struct net_device *dev)
{
struct dev_mc_list *iter;
- int i;
u8 tmp;
u32 mbp, bit, hash[2] = { 0, };
struct cpmac_priv *priv = netdev_priv(dev);
@@ -340,8 +339,7 @@ static void cpmac_set_multicast_list(struct net_device *dev)
* cpmac uses some strange mac address hashing
* (not crc32)
*/
- for (i = 0, iter = dev->mc_list; i < netdev_mc_count(dev);
- i++, iter = iter->next) {
+ netdev_for_each_mc_addr(iter, dev) {
bit = 0;
tmp = iter->dmi_addr[0];
bit ^= (tmp >> 2) ^ (tmp << 4);