diff options
author | Jiri Pirko <jpirko@redhat.com> | 2010-02-23 23:17:07 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-26 02:07:31 -0800 |
commit | 567ec874d15b478c8eda7e9a5d2dcb05f13f1fb5 (patch) | |
tree | e0c22740e44eca6f035e7dccbcff114a72d007a3 /drivers/net/tlan.c | |
parent | f9dcbcc9e338d08c0f7de7eba4eaafbbb7f81249 (diff) |
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>
Diffstat (limited to 'drivers/net/tlan.c')
-rw-r--r-- | drivers/net/tlan.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/tlan.c b/drivers/net/tlan.c index e44d5a074c6..390540c101c 100644 --- a/drivers/net/tlan.c +++ b/drivers/net/tlan.c @@ -1314,7 +1314,7 @@ static struct net_device_stats *TLan_GetStats( struct net_device *dev ) static void TLan_SetMulticastList( struct net_device *dev ) { - struct dev_mc_list *dmi = dev->mc_list; + struct dev_mc_list *dmi; u32 hash1 = 0; u32 hash2 = 0; int i; @@ -1335,7 +1335,8 @@ static void TLan_SetMulticastList( struct net_device *dev ) TLan_DioWrite32( dev->base_addr, TLAN_HASH_1, 0xFFFFFFFF ); TLan_DioWrite32( dev->base_addr, TLAN_HASH_2, 0xFFFFFFFF ); } else { - for ( i = 0; i < netdev_mc_count(dev); i++ ) { + i = 0; + netdev_for_each_mc_addr(dmi, dev) { if ( i < 3 ) { TLan_SetMac( dev, i + 1, (char *) &dmi->dmi_addr ); @@ -1346,7 +1347,7 @@ static void TLan_SetMulticastList( struct net_device *dev ) else hash2 |= ( 1 << ( offset - 32 ) ); } - dmi = dmi->next; + i++; } for ( ; i < 3; i++ ) TLan_SetMac( dev, i + 1, NULL ); |