All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [TG3 2/8]: Use lower DMA watermark for 5703.
  2007-02-13 20:14 [TG3 2/8]: Use lower DMA watermark for 5703 Michael Chan
@ 2007-02-13 19:42 ` Jeff Garzik
  2007-02-13 20:19 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Jeff Garzik @ 2007-02-13 19:42 UTC (permalink / raw)
  To: Michael Chan; +Cc: davem, netdev

On Tue, Feb 13, 2007 at 12:14:01PM -0800, Michael Chan wrote:
> [TG3]: Use lower DMA watermark for 5703.
> 
> Set DMA read watermark to 4 on 5703 in PCIX mode.  This is needed to
> prevent some tx timeouts.
> 
> Signed-off-by: Michael Chan <mchan@broadcom.com>

ACK patches 2-8



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

* [TG3 2/8]: Use lower DMA watermark for 5703.
@ 2007-02-13 20:14 Michael Chan
  2007-02-13 19:42 ` Jeff Garzik
  2007-02-13 20:19 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Michael Chan @ 2007-02-13 20:14 UTC (permalink / raw)
  To: davem, netdev

[TG3]: Use lower DMA watermark for 5703.

Set DMA read watermark to 4 on 5703 in PCIX mode.  This is needed to
prevent some tx timeouts.

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

diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index 0b5b8e7..2df343f 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -11314,6 +11314,7 @@ static int __devinit tg3_test_dma(struct
 		if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5703 ||
 		    GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5704) {
 			u32 ccval = (tr32(TG3PCI_CLOCK_CTRL) & 0x1f);
+			u32 read_water = 0x7;
 
 			/* If the 5704 is behind the EPB bridge, we can
 			 * do the less restrictive ONE_DMA workaround for
@@ -11325,8 +11326,13 @@ static int __devinit tg3_test_dma(struct
 			else if (ccval == 0x6 || ccval == 0x7)
 				tp->dma_rwctrl |= DMA_RWCTRL_ONE_DMA;
 
+			if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5703)
+				read_water = 4;
 			/* Set bit 23 to enable PCIX hw bug fix */
-			tp->dma_rwctrl |= 0x009f0000;
+			tp->dma_rwctrl |=
+				(read_water << DMA_RWCTRL_READ_WATER_SHIFT) |
+				(0x3 << DMA_RWCTRL_WRITE_WATER_SHIFT) |
+				(1 << 23);
 		} else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5780) {
 			/* 5780 always in PCIX mode */
 			tp->dma_rwctrl |= 0x00144000;



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

* Re: [TG3 2/8]: Use lower DMA watermark for 5703.
  2007-02-13 20:14 [TG3 2/8]: Use lower DMA watermark for 5703 Michael Chan
  2007-02-13 19:42 ` Jeff Garzik
@ 2007-02-13 20:19 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2007-02-13 20:19 UTC (permalink / raw)
  To: mchan; +Cc: netdev

From: "Michael Chan" <mchan@broadcom.com>
Date: Tue, 13 Feb 2007 12:14:01 -0800

> [TG3]: Use lower DMA watermark for 5703.
> 
> Set DMA read watermark to 4 on 5703 in PCIX mode.  This is needed to
> prevent some tx timeouts.
> 
> Signed-off-by: Michael Chan <mchan@broadcom.com>

Applied.

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

end of thread, other threads:[~2007-02-13 20:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-13 20:14 [TG3 2/8]: Use lower DMA watermark for 5703 Michael Chan
2007-02-13 19:42 ` Jeff Garzik
2007-02-13 20:19 ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.