summaryrefslogtreecommitdiff
path: root/drivers/net/usb/catc.c
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2010-02-18 07:02:26 +0300
committerDavid S. Miller <davem@davemloft.net>2010-02-19 01:47:50 +0300
commita92635dc77b14f0f28d45c0fbf91b5064d9d7617 (patch)
treeefc3a7a9a4b559614e56339aaa26171495bfb0c9 /drivers/net/usb/catc.c
parent4302b67e041ea81c8fc233bee1296516e1294a27 (diff)
downloadlinux-a92635dc77b14f0f28d45c0fbf91b5064d9d7617.tar.xz
net/usb: convert to use netdev_for_each_mc_addr
also removed needless checks in smsc95xx Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/usb/catc.c')
-rw-r--r--drivers/net/usb/catc.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/usb/catc.c b/drivers/net/usb/catc.c
index 5a13660ebd17..96f1ebe0d348 100644
--- a/drivers/net/usb/catc.c
+++ b/drivers/net/usb/catc.c
@@ -632,7 +632,6 @@ static void catc_set_multicast_list(struct net_device *netdev)
struct dev_mc_list *mc;
u8 broadcast[6];
u8 rx = RxEnable | RxPolarity | RxMultiCast;
- int i;
memset(broadcast, 0xff, 6);
memset(catc->multicast, 0, 64);
@@ -648,9 +647,7 @@ static void catc_set_multicast_list(struct net_device *netdev)
if (netdev->flags & IFF_ALLMULTI) {
memset(catc->multicast, 0xff, 64);
} else {
- for (i = 0, mc = netdev->mc_list;
- mc && i < netdev_mc_count(netdev);
- i++, mc = mc->next) {
+ netdev_for_each_mc_addr(mc, netdev) {
u32 crc = ether_crc_le(6, mc->dmi_addr);
if (!catc->is_f5u011) {
catc->multicast[(crc >> 3) & 0x3f] |= 1 << (crc & 7);