aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/jme.c
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2010-02-23 04:19:49 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-26 05:07:30 -0500
commitf9dcbcc9e338d08c0f7de7eba4eaafbbb7f81249 (patch)
tree8a1d9a37bc057440220a5ad23231e0fe974b93f6 /drivers/net/jme.c
parent52c793f24054f5dc30d228e37e0e19cc8313f086 (diff)
net: convert multiple drivers to use netdev_for_each_mc_addr, part5 V2
removed some needless checks and also corrected bug in lp486e (dmi was passed instead of dmi->dmi_addr) Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/jme.c')
-rw-r--r--drivers/net/jme.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/net/jme.c b/drivers/net/jme.c
index 558b6a0b15fc..0f31497833df 100644
--- a/drivers/net/jme.c
+++ b/drivers/net/jme.c
@@ -1997,7 +1997,6 @@ jme_set_multi(struct net_device *netdev)
1997{ 1997{
1998 struct jme_adapter *jme = netdev_priv(netdev); 1998 struct jme_adapter *jme = netdev_priv(netdev);
1999 u32 mc_hash[2] = {}; 1999 u32 mc_hash[2] = {};
2000 int i;
2001 2000
2002 spin_lock_bh(&jme->rxmcs_lock); 2001 spin_lock_bh(&jme->rxmcs_lock);
2003 2002
@@ -2012,10 +2011,7 @@ jme_set_multi(struct net_device *netdev)
2012 int bit_nr; 2011 int bit_nr;
2013 2012
2014 jme->reg_rxmcs |= RXMCS_MULFRAME | RXMCS_MULFILTERED; 2013 jme->reg_rxmcs |= RXMCS_MULFRAME | RXMCS_MULFILTERED;
2015 for (i = 0, mclist = netdev->mc_list; 2014 netdev_for_each_mc_addr(mclist, netdev) {
2016 mclist && i < netdev_mc_count(netdev);
2017 ++i, mclist = mclist->next) {
2018
2019 bit_nr = ether_crc(ETH_ALEN, mclist->dmi_addr) & 0x3F; 2015 bit_nr = ether_crc(ETH_ALEN, mclist->dmi_addr) & 0x3F;
2020 mc_hash[bit_nr >> 5] |= 1 << (bit_nr & 0x1F); 2016 mc_hash[bit_nr >> 5] |= 1 << (bit_nr & 0x1F);
2021 } 2017 }