summaryrefslogtreecommitdiff
path: root/cleopatre
diff options
context:
space:
mode:
authorYacine Belkadi2011-07-04 14:56:59 +0200
committerYacine Belkadi2011-08-12 17:31:22 +0200
commite30ebd49bcdd6e930a2c7525a79316cc6dd3faf7 (patch)
treee3110c08e06d3b5ffb0c5c0a79558f154be7e1b5 /cleopatre
parent099c06c1475d8792a56f17523e319f36e623e601 (diff)
cleo/linux/drv/eth: flow control: set Pause Time to 65535 quanta, refs #2487
The Ethernet Hardware is configured to send a pause frame (with some pause time value) when the use of the Rx FIFO reaches a configured threshold. This pause frame asks the other end to stop sending packets for the specified duration (the pause time). The Ethernet hardware is configured to send a pause frame with 0 quanta as the pause time, when the use of the Rx FIFO falls to an other configured threshold. This pause frame with a zero pause time asks the other end to resume the sending of packets. Because: 1) the first pause frame is sent again if the initial pause time is almost expired (cf. Pause Low Threshold), 2) a zero pause frame is sent when the hardware is able to receive again, the mechanism is like an X-OFF/X-ON mechanism: Stop transmission/Resume transmission. So it seems appropriate to set the Pause Time to the maximum possible value: 65535.
Diffstat (limited to 'cleopatre')
-rw-r--r--cleopatre/linux-2.6.25.10-spc300/drivers/net/arm/synop3504_hw.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cleopatre/linux-2.6.25.10-spc300/drivers/net/arm/synop3504_hw.c b/cleopatre/linux-2.6.25.10-spc300/drivers/net/arm/synop3504_hw.c
index f13d909a6a..394148a539 100644
--- a/cleopatre/linux-2.6.25.10-spc300/drivers/net/arm/synop3504_hw.c
+++ b/cleopatre/linux-2.6.25.10-spc300/drivers/net/arm/synop3504_hw.c
@@ -209,8 +209,8 @@ void SynopsysInit(Synopsys *synop, uint32_t txaddr, uint32_t rxaddr)
GmacSelectMii|GmacLoopbackOff|GmacFESpeed10|GmacFullDuplex|
GmacTxEnable|GmacRxEnable);
}
- SynopsysWriteMacReg(synop, GmacFlowControl, GmacFlowCtrlTxEn | GmacFlowCtrlRxEn | GmacFlowCtrlThresh144 | GmacFlowCtrlUnicast |
- ((0x1000 << GmacFlowCtrlTimePauseShift) & GmacFlowCtrlTimePauseMask));
+ SynopsysWriteMacReg(synop, GmacFlowControl, GmacFlowCtrlTxEn | GmacFlowCtrlRxEn | GmacFlowCtrlThresh4 | GmacFlowCtrlUnicast |
+ ((0xFFFF << GmacFlowCtrlTimePauseShift) & GmacFlowCtrlTimePauseMask));
TRACE(" GmacIntMask=%x\n",SynopsysReadMacReg(synop, GmacIntMask));
TRACE(" MmcIntMaskTx=%x\n",SynopsysReadMacReg(synop, MmcIntrMaskTx));
TRACE(" MmcIntMaskRx=%x\n",SynopsysReadMacReg(synop, MmcIntrMaskRx));