Skip to contentSkip to conversation

r6040: fix check against MCRO_HASHEN bit in r6040_multicast_list

PATCH Applied Florian Fainelli 2 participants 2 messages Nov 16, 2011 – Nov 17, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 r6040: fix check against MCRO_HASHEN bit in r6040_multicast_list

We are checking whether the MCR0_HASHEN bit is set using a logical and instead of bitwise and, fix that.

---
 drivers/net/ethernet/rdc/r6040.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/net/ethernet/rdc/r6040.c +1 -1
index 1fc01ca..4bf68cf 100644
@@ -940,7 +940,7 @@ static void r6040_multicast_list(struct net_device *dev)
 	iowrite16(lp->mcr0, ioaddr + MCR0);
 
 	/* Fill the MAC hash tables with their values */
-	if (lp->mcr0 && MCR0_HASH_EN) {
+	if (lp->mcr0 & MCR0_HASH_EN) {
 		iowrite16(hash_table[0], ioaddr + MAR0);
 		iowrite16(hash_table[1], ioaddr + MAR1);
 		iowrite16(hash_table[2], ioaddr + MAR2);
Signature · 1 line
1.7.5.4