zl50404 Zarlink Semiconductor, zl50404 Datasheet - Page 37

no-image

zl50404

Manufacturer Part Number
zl50404
Description
Lightly Managed/unmanaged 5-port 10/100m Ethernet Switch
Manufacturer
Zarlink Semiconductor
Datasheet
ZL50404
Data Sheet
Also, when shaping is enabled, it is possible for a queue to explode in length if fed by a greedy source. The reason
is that a shaper is by definition not work-conserving; that is, it may hold back from sending a packet even if the line
is idle. Though we do have global resource management, we do nothing other than per port WRED to prevent this
situation locally. We assume the traffic is policed at a prior stage to the ZL50404 or WRED dropping is fine and shall
restrain this situation.
7.5
Rate Control
The ZL50404 provides a rate control function on its RMAC ports. This rate control function applies to both the
incoming and outgoing traffic aggregate on each RMAC port. It provides a way of reducing the average rate below
full wire speed. Note that the rate control function does not shape or manipulate any particular traffic class.
Furthermore, though the average rate of the port can be controlled with this function, the peak rate will still be full
line rate.
Two principal parameters are used to control the average rate for a RMAC port. A port’s rate is controlled by
allowing, on average, M bytes to be transmitted every N microseconds. Both of these values are programmable.
The user can program the number of bytes in 8-byte increments, and the time may be set in units of 10us or 1ms.
The value of M/N will, of course, equal the average data rate of the traffic aggregate on the given RMAC port.
Although there are many (M,N) pairs that will provide the same average data rate performance, the smaller the time
interval N, the “smoother” the output pattern will appear.
In addition to controlling the average data rate on a RMAC port, the rate control function also manages the
maximum burst size at wire speed. The maximum burst size can be considered the memory of the rate control
mechanism; if the line has been idle for a long time, to what extent can the port “make up for lost time” by
transmitting a large burst? This value is also programmable, measured in 8-byte increments.
Example: Suppose that the user wants to restrict Fast Ethernet port P’s average departure rate to 32 Mbps – 32%
of line rate – when the average is taken over a period of 10 ms. In an interval of 10 ms, exactly 40000 bytes can be
transmitted at an average rate of 32 Mbps.
So how do we set the parameters?
The rate control parameters are contained in an internal RAM block
accessible through the CPU port (See Rate Control application note, ZLAN-33). The data format is shown below.
63:40
39:32
31:16
15:0
0
Time interval
Maximum burst size
Number of bytes
As we indicated earlier, the number of bytes is measured in 8-byte increments, so the 16-bit field “Number of bytes”
should be set to 40000/8, or 5000. In addition, the time interval has to be set to 10 in units of 1 ms. Though we want
the average data rate on port P to be 32 Mbps when measured over an interval of 10 ms, we can also adjust the
maximum number of bytes that can be transmitted at full line rate in any single burst. Suppose we wish this limit to
be 12 kilobytes. The number of bytes is measured in 8-byte increments, so the 16-bit field “Maximum burst size” is
set to 12000/8, or 1500.
The action on the incoming traffic and outgoing traffic when credit is not available are different. For the outgoing
traffic, the queued frames will be held in the queue until the credit become available. The consequence of this
holding is the exploding queue size that may cause dropping on the receiving side. The capability of ZL50404 on
this perspective is quite limited due to the small frame buffer on chip. The actions on the incoming traffic depending
on the flow control state of that port. If the ingress port flow control is turned on, the XOFF flow control will be
triggered when the credit is running lower than half of the maximum burst size. The XON will be triggered when the
available credit is increased to above the threshold. If the port flow control is disabled, the received traffic will
subject to WRED depending on the credit availability. If the none of the credit is available, all received frame will be
dropped. If only a quarter of maximum burst credits are available, the frame that been marked as high drop will be
drop 100%, the low drop frame will be dropped at ra%, If half of the maximum burst credits are available, high drop
frame will be dropped at rb%. The ra% and rb% can be programmed by RDRC2 register.
37
Zarlink Semiconductor Inc.

Related parts for zl50404