netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings
@ 2005-03-21  8:02 Michael Chan
  2005-03-22 20:58 ` Jeff Garzik
  2005-03-23 19:11 ` David S. Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Michael Chan @ 2005-03-21  8:02 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev

[-- Attachment #1: Type: text/plain, Size: 320 bytes --]

Fix jumbo frame settings on all copper phys that support jumbo frames by
setting the fifo elasticity bit. This setting is for the phy's tx fifo to
properly handle jumbo frames. Note that a similar jumbo frame fix for the
phy's rx fifo was made to tg3 in the past.

Signed-off-by: Michael Chan <mchan@broadcom.com>

[-- Attachment #2: tg3-6.patch --]
[-- Type: application/octet-stream, Size: 1186 bytes --]

diff -Nru 6/drivers/net/tg3.c 7/drivers/net/tg3.c
--- 6/drivers/net/tg3.c	2005-03-17 18:51:38.000000000 -0800
+++ 7/drivers/net/tg3.c	2005-03-18 16:41:59.000000000 -0800
@@ -868,6 +868,19 @@
 		    !tg3_readphy(tp, MII_TG3_AUX_CTRL, &phy_reg))
 			tg3_writephy(tp, MII_TG3_AUX_CTRL, phy_reg | 0x4000);
 	}
+
+	/* Set phy register 0x10 bit 0 to high fifo elasticity to support
+	 * jumbo frames transmission.
+	 */
+	if (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5705 &&
+	    GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5750) {
+		u32 phy_reg;
+
+		if (!tg3_readphy(tp, MII_TG3_EXT_CTRL, &phy_reg))
+		    tg3_writephy(tp, MII_TG3_EXT_CTRL,
+				 phy_reg | MII_TG3_EXT_CTRL_FIFO_ELASTIC);
+	}
+
 	tg3_phy_set_wirespeed(tp);
 	return 0;
 }
diff -Nru 6/drivers/net/tg3.h 7/drivers/net/tg3.h
--- 6/drivers/net/tg3.h	2005-03-17 18:51:42.000000000 -0800
+++ 7/drivers/net/tg3.h	2005-03-18 16:42:03.000000000 -0800
@@ -1518,6 +1518,7 @@
 #define  MII_TG3_CTRL_ENABLE_AS_MASTER	0x1000
 
 #define MII_TG3_EXT_CTRL		0x10 /* Extended control register */
+#define  MII_TG3_EXT_CTRL_FIFO_ELASTIC	0x0001
 #define  MII_TG3_EXT_CTRL_LNK3_LED_MODE	0x0002
 #define  MII_TG3_EXT_CTRL_TBI		0x8000
 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings
  2005-03-21  8:02 [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings Michael Chan
@ 2005-03-22 20:58 ` Jeff Garzik
  2005-03-23 19:11 ` David S. Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Jeff Garzik @ 2005-03-22 20:58 UTC (permalink / raw)
  To: Michael Chan; +Cc: David S. Miller, netdev

Michael Chan wrote:
> Fix jumbo frame settings on all copper phys that support jumbo frames by
> setting the fifo elasticity bit. This setting is for the phy's tx fifo to
> properly handle jumbo frames. Note that a similar jumbo frame fix for the
> phy's rx fifo was made to tg3 in the past.
> 
> Signed-off-by: Michael Chan <mchan@broadcom.com

ACK

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings
  2005-03-21  8:02 [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings Michael Chan
  2005-03-22 20:58 ` Jeff Garzik
@ 2005-03-23 19:11 ` David S. Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David S. Miller @ 2005-03-23 19:11 UTC (permalink / raw)
  To: Michael Chan; +Cc: netdev

On Mon, 21 Mar 2005 00:02:02 -0800
"Michael Chan" <mchan@broadcom.com> wrote:

> Fix jumbo frame settings on all copper phys that support jumbo frames by
> setting the fifo elasticity bit. This setting is for the phy's tx fifo to
> properly handle jumbo frames. Note that a similar jumbo frame fix for the
> phy's rx fifo was made to tg3 in the past.
> 
> Signed-off-by: Michael Chan <mchan@broadcom.com>

Applied, thanks Michael.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-03-23 19:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-21  8:02 [PATCH 2.6.11 6/8] tg3: Fix jumbo frames phy settings Michael Chan
2005-03-22 20:58 ` Jeff Garzik
2005-03-23 19:11 ` David S. Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).