User Manual
BCM1250/BCM1125/BCM1125H
10/21/02
B r o a d c o m C o r p o r a t i o n
Document
1250_1125-UM100CB-R
Section 9: Ethernet MACs Page
293
Flow Control In Encoded Packet FIFO Modes
Flow control is available in the encoded packet fifo modes. In addition to the DMA descriptor based flow control
there is a link level flow control.
The transmitter can be controlled by the COL input in 8 bit mode and the TXFC input in 16 bit mode (note that
these are the same physical pin). Since the input is synchronized internally there is some uncertainty in the
number of additional bytes that can be transmitted following assertion of the flow control signal. The transmitter
will stop:
•
2-4 cycles after TXFC assertion in 16 bit mode no CRC (4-8 bytes)
•
2-6 cycles after TXFC assertion in 16 bit mode + CRC (4-12 bytes)
•
2-4 cycles after TXFC assertion in 8 bit mode no CRC (2-4 bytes)
•
2-8 cycles after TXFC assertion in 8 bit mode + CRC (2-8 bytes)
The receiver will assert its flow control output (MDIO in 8 bit mode, RXFC in 16 bit mode) either because the
DMA watermark state requests flow control or to prevent the receive fifo overflowing. The enc_fc_thrsh field in
the
mac_thrsh_cfg
register sets the flow control threshold. Flow control will be requested when there are
fewer than this number of doublewords free in the fifo. There is a 1 cycle delay from the number of entries in
the fifo falling below the threshold and the external signal being asserted, and there can be up to 10 cycles of
data (10 bytes in 8 bit mode, 20 bytes in 16 bit mode) in flight between the receive data pins and the fifo.
As an example consider connecting two parts back-to-back. With the default threshold of 4 double words (32
bytes) in 16 bit mode there can be 22 bytes (2 from the one cycle delay and 20 in flight) added to the receive
fifo if the transmitter stopped instantaneously. However, there is additional delay. If CRCs are not being
appended by the transmitter an additional 8 bytes could be sent, leaving two bytes margin. But if the transmitter
was appending CRC then the additional 12 bytes would cause the receive fifo to overflow, so the threshold
must be increased to 5 doublewords.
Note that the direction of the MDIO/RCFC pin is controllable by software using the mdio_dir bit in the
mac_mdio
register. This must be set for output (which is the default) when receive flow control is being used.
8-B
IT
P
ACKET
FIFO O
PERATION
There are two models for running the Packet FIFO. In the packet model Start of Packet (SOP) and End of
Packet (EOP) data are flagged and all data between these marks are counted as a single packet and passed
through the DMA engine in the same way an Ethernet packet would be. In this packet based model once a
SOP has been seen further SOP signals are ignored until an EOP has been triggered. The second model is
to have an unframed data stream, in this case the DMA will run through filling DMA buffers in sequence for as
long as there are descriptors available.
The receive filtering options are described in
Section: “Packet FIFO Interfaces” on page 292
. If an unframed
data stream is being received software must ensure that the
mac_chup
and
mac_chlo
tables select the same
DMA channel at all indices.
Packets transmitted in any of the modes can have a CRC-32 appended by setting the append CRC bit in the
transmit packet descriptor. Packets received have their final four bytes checked for a valid CRC-32 and if the
bypass_fcs_chk bit is set in the
mac_cfg
register the status bit in the receive descriptor will be set accordingly
(if the bypass_fcs_chk bit is clear the status word will never flag a CRC error). If the CRC-32 is used on the
receive side there must be at least seven clock cycles between the end of packet and the start of the next
packet. If this inter-frame gap is not provided then the CRC checker will give UNPREDICTABLE results.
Содержание BCM1125
Страница 18: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page xviii Document 1250_1125 UM100CB R ...
Страница 28: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page xxviii Document 1250_1125 UM100CB R ...
Страница 515: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page vii Index Document 1250_1125 UM100CB R ...