Skip to contentSkip to conversation

Fix typo in meth driver

PATCH Applied Christoph Lameter 2 participants 2 messages Jul 11, 2008 – Jul 22, 2008

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

An | in an if statement to check a bit? I think this needs to be a &. As a result of this typo meth will always operate in promiscuous mode.

drivers/net/meth.c +1 -1
Index: linux-2.6/drivers/net/meth.c
===================================================================
@@ -287,7 +287,7 @@
 
 	/* Initial mode: 10 | Half-duplex | Accept normal packets */
 	priv->mac_ctrl = METH_ACCEPT_MCAST | METH_DEFAULT_IPG;
-	if (dev->flags | IFF_PROMISC)
+	if (dev->flags & IFF_PROMISC)
 		priv->mac_ctrl |= METH_PROMISC;
 	mace->eth.mac_ctrl = priv->mac_ctrl;
 
Applied
#1 lore raw
Quoted 10 lines · Christoph Lameter

An | in an if statement to check a bit? I think this needs to be a &. As a result of this typo meth will always operate in promiscuous mode.

Index: linux-2.6/drivers/net/meth.c
===================================================================

drivers/net/meth.c line 293

Quoted 8 lines
drivers/net/meth.c +1 -1
@@ -287,7 +287,7 @@
 
 	/* Initial mode: 10 | Half-duplex | Accept normal packets */
 	priv->mac_ctrl = METH_ACCEPT_MCAST | METH_DEFAULT_IPG;
-	if (dev->flags | IFF_PROMISC)
+	if (dev->flags & IFF_PROMISC)
 		priv->mac_ctrl |= METH_PROMISC;
 	mace->eth.mac_ctrl = priv->mac_ctrl;
 

applied