Skip to content

Commit

Permalink
net: am79c961a: Omit check for multicast bit in netdev_for_each_mc_addr
Browse files Browse the repository at this point in the history
There is no need to check for the address being a multicast address in
the netdev_for_each_mc_addr loop, so remove it.

Signed-off-by: Tobias Klauser <[email protected]>
Acked-by: Russell King <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
tklauser authored and davem330 committed Jul 1, 2011
1 parent 0311ee2 commit bda7ed4
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions drivers/net/arm/am79c961a.c
Original file line number Diff line number Diff line change
Expand Up @@ -199,17 +199,15 @@ am79c961_ramtest(struct net_device *dev, unsigned int val)

static void am79c961_mc_hash(char *addr, u16 *hash)
{
if (addr[0] & 0x01) {
int idx, bit;
u32 crc;
int idx, bit;
u32 crc;

crc = ether_crc_le(ETH_ALEN, addr);
crc = ether_crc_le(ETH_ALEN, addr);

idx = crc >> 30;
bit = (crc >> 26) & 15;
idx = crc >> 30;
bit = (crc >> 26) & 15;

hash[idx] |= 1 << bit;
}
hash[idx] |= 1 << bit;
}

static unsigned int am79c961_get_rx_mode(struct net_device *dev, u16 *hash)
Expand Down

0 comments on commit bda7ed4

Please sign in to comment.