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
283
F
LOW
C
ONTROL
The MAC supports flow control in both full-duplex and half-duplex modes. In full-duplex mode pause frames
are used to request the peer to stop sending for a particular length of time. In half-duplex mode back-pressure
is applied by forcing the physical layer into not allowing transmissions.
Flow control can be explicitly invoked by setting the fc_sel bit in the
mac_cfg
register, or it can be requested
automatically by the interface when the number of receive DMA buffers falls below the low watermark (see
Section: “Descriptor Count Watermarks” on page 157
). Flow control is invoked if any of the sources request it.
The flow control method used when the interface is unable to accept data is set by the fc_cmd field in the
mac_cfg
register, as shown in
If the interface is operating in half-duplex mode and flow control is invoked back pressure will be applied. If the
fc_cmd field is set to 2'b01 back pressure is generated by the collision method. The interface forces collisions
on the link by transmitting the collision data pattern. If the carrier is not currently being detected, or the protocol
engine has not yet received more than the number of bytes set in the ifg_rx field of the
mac_frame_cfg
register
then the collision transmission begins immediately. If more than the threshold number of bytes have been
received in the current packet the collision will not be forced until after the incoming packet has completed (to
avoid a late collision). Packet transmission is still possible when back pressure is applied in this way. If there
is an outgoing packet it will contend for access in the usual manner. If the transmitter gains the link then the
packet can be sent normally, if it loses then the back pressure machine will cause collisions with the packet
that another source is trying to send.
In half-duplex mode if fc_cmd is set to 2'b10 the interface will apply back pressure by causing a false carrier
sense. This is done by sending the collision data pattern (i.e. generating a carrier) after only 1/3rd of inter-frame
gap time has elapsed since the carrier was last detected. This causes all other sources to sense a carrier and
backoff. The carrier must be continually generated to ensure the other stations continue to detect it, so it is not
possible to transmit packets while using this method.
If the interface is operating in full-duplex mode, flow control is applied by transmitting a Pause Frame. A frame
is created with the Pause Count (the number of slot times that the peer should not transmit) set to the value
encoded in the tx_pause_cnt field in the
mac_cfg
register. When a pause is requested the slot times are also
counted locally. Towards the end of the period if the interface can still not accept packets an additional pause
frame will be sent, requesting another pause in transmission by the peer. If flow control is no longer needed
because DMA buffers have been added or the fc_sel bit has cleared, or if flow control is disabled by the fc_cmd
field being set to 2'b00, then a Pause Frame is immediately sent with a zero Pause Count to restart the peer.
Table 164: Back Pressure Methods in Half-Duplex Operation
fc_cmd
Half-Duplex Back Pressure Method
2'b00
Disabled
2'b01
Force Collision
2'b10
False Carrier
2'b11
Reserved