Skip to contentSkip to conversation

tg3: Fix return ring size breakage

PATCH In review mcarlson 2 participants 2 messages Sep 11, 2009

Subsystems (2)
lore
Share & tools
lore

mcarlson

author
#0 lore raw

PATCH 1/1 tg3: Fix return ring size breakage

Commit f6eb9b1fc1411d22c073f5264e5630a541d0f7df, "tg3: Add 5717 asic rev" changed how the rx return ring size operations are done. It effectively inverts the sense of the previous test, but it failed to also invert the resulting sizes. This patch corrects that error.

---
 drivers/net/tg3.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/net/tg3.c +1 -1
index 7cf8000..f09bc5d 100644
@@ -112,7 +112,7 @@
  */
 #define TG3_RX_RCB_RING_SIZE(tp)	\
 	(((tp->tg3_flags & TG3_FLAG_JUMBO_CAPABLE) && \
-	  !(tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) ? 512 : 1024)
+	  !(tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) ? 1024 : 512)
 
 #define TG3_TX_RING_SIZE		512
 #define TG3_DEF_TX_RING_PENDING		(TG3_TX_RING_SIZE - 1)
Signature · 1 line
1.6.3.3
maintainer
#1 lore raw

From: mcarlson <[email protected]>
Date: Fri, 11 Sep 2009 16:23:19 -0700

Quoted 6 lines

Commit f6eb9b1fc1411d22c073f5264e5630a541d0f7df, "tg3: Add 5717 asic rev" changed how the rx return ring size operations are done. It effectively inverts the sense of the previous test, but it failed to also invert the resulting sizes. This patch corrects that error.

Confirmed to fix things here, applied, thanks!