Skip to contentSkip to conversation

fix "&& 0x03" obvious typo in net1080

PATCH In review Willy Tarreau 3 participants 4 messages Nov 19, 2006 – Nov 21, 2006 USB

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix "&& 0x03" obvious typo in net1080

Hi David,

I found this bug while grepping for "&& 0x" in drivers. Care to forward upstream ?

Regards,
Willy

Quoted 1 line

From e9b19b98763726db99237ccfea907cf88d3572ac Mon Sep 17 00:00:00 2001

From: Willy Tarreau <[email protected]>
Date: Sun, 19 Nov 2006 15:30:11 +0100
Subject: [PATCH] fix "&& 0x03" obvious typo in net1080

Another obvious occurrence of this typo.

---
 drivers/usb/net/net1080.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/usb/net/net1080.c +2 -2
index ce00de8..a774105 100644
@@ -237,12 +237,12 @@ #define	STATUS_PORT_A		(1 << 15)
 #define	STATUS_CONN_OTHER	(1 << 14)
 #define	STATUS_SUSPEND_OTHER	(1 << 13)
 #define	STATUS_MAILBOX_OTHER	(1 << 12)
-#define	STATUS_PACKETS_OTHER(n)	(((n) >> 8) && 0x03)
+#define	STATUS_PACKETS_OTHER(n)	(((n) >> 8) & 0x03)
 
 #define	STATUS_CONN_THIS	(1 << 6)
 #define	STATUS_SUSPEND_THIS	(1 << 5)
 #define	STATUS_MAILBOX_THIS	(1 << 4)
-#define	STATUS_PACKETS_THIS(n)	(((n) >> 0) && 0x03)
+#define	STATUS_PACKETS_THIS(n)	(((n) >> 0) & 0x03)
 
 #define	STATUS_UNSPEC_MASK	0x0c8c
 #define	STATUS_NOISE_MASK 	((u16)~(0x0303|STATUS_UNSPEC_MASK))
Signature · 1 line
1.4.2.4
#1 lore raw
Quoted 4 lines · Willy Tarreau

Hi David,

I found this bug while grepping for "&& 0x" in drivers. Care to forward upstream ?

I thought this already _was_ upstream ... Greg?

Quoted 37 lines

Regards,
Willy

Quoted 1 line

From e9b19b98763726db99237ccfea907cf88d3572ac Mon Sep 17 00:00:00 2001

From: Willy Tarreau <[email protected]>
Date: Sun, 19 Nov 2006 15:30:11 +0100
Subject: [PATCH] fix "&& 0x03" obvious typo in net1080

Another obvious occurrence of this typo.

---
 drivers/usb/net/net1080.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/usb/net/net1080.c +2 -2
index ce00de8..a774105 100644
@@ -237,12 +237,12 @@ #define	STATUS_PORT_A		(1 << 15)
 #define	STATUS_CONN_OTHER	(1 << 14)
 #define	STATUS_SUSPEND_OTHER	(1 << 13)
 #define	STATUS_MAILBOX_OTHER	(1 << 12)
-#define	STATUS_PACKETS_OTHER(n)	(((n) >> 8) && 0x03)
+#define	STATUS_PACKETS_OTHER(n)	(((n) >> 8) & 0x03)
 
 #define	STATUS_CONN_THIS	(1 << 6)
 #define	STATUS_SUSPEND_THIS	(1 << 5)
 #define	STATUS_MAILBOX_THIS	(1 << 4)
-#define	STATUS_PACKETS_THIS(n)	(((n) >> 0) && 0x03)
+#define	STATUS_PACKETS_THIS(n)	(((n) >> 0) & 0x03)
 
 #define	STATUS_UNSPEC_MASK	0x0c8c
 #define	STATUS_NOISE_MASK 	((u16)~(0x0303|STATUS_UNSPEC_MASK))
Signature · 1 line
1.4.2.4
#2 lore raw
Quoted 7 lines · David Brownell
Quoted 4 lines · Willy Tarreau

Hi David,

I found this bug while grepping for "&& 0x" in drivers. Care to forward upstream ?

I thought this already _was_ upstream ... Greg?

It's in my tree, and in the next -mm. I didn't send it to Linus for 2.6.19, as it's only a debug issue, like you mentioned.

So it's in the pipeline...

thanks,

greg k-h

#3 lore raw
Quoted 7 lines · Greg KH
Quoted 6 lines · David Brownell
Quoted 4 lines · Willy Tarreau

Hi David,

I found this bug while grepping for "&& 0x" in drivers. Care to forward upstream ?

Quoted 6 lines
Quoted 1 line

I thought this already _was_ upstream ... Greg?

It's in my tree, and in the next -mm. I didn't send it to Linus for 2.6.19, as it's only a debug issue, like you mentioned.

So it's in the pipeline...

OK, that explains why I did not find it fixed first :-)

Thanks guys,
Willy