
80
Functional Operation
Chapter 3
AMD-8111 HyperTransport I/O Hub Data Sheet
24674
Rev. 3.00
April 2003
AMD Preliminary Information
defined priority scheme. The manner in which this scheme relates to standards such as IEEE 802.1 P
is described elsewhere in this document. This section simply describes the implementation of the
descriptor rings themselves.
Each descriptor describes a single buffer. A frame may occupy one or more buffers. If multiple
buffers are used, this is referred to as buffer chaining.
Transmit buffers can be of any size and can start at any byte address. Receive buffers can start at any
byte address, but there is a restriction on receive buffer length. Either the length of a receive buffer
must be a multiple of 4 bytes, or the length of the receive buffer must be at least as large as the longest
frame that the software can accept.
Each descriptor ring must occupy a contiguous area of memory. The user-defined base addresses for
the transmit and receive descriptor rings are set up during initialization in the BADR0 and BADX0-3
registers. The number of descriptors in each ring is written into the RCV_RING0_LEN and
XMT_RINGx_LEN registers, where x indicates the transmit ring number.
The descriptor ring base addresses must be aligned to 16-byte boundaries. Each ring entry is
organized as four 32-bit message descriptors. Ring lengths can be of any size up to 65535 descriptors.
Each ring entry contains the following information:
The address of the actual message data buffer in user or host memory
The length of the message buffer
Status information indicating the condition of the buffer
See Figure 32 on page 347 and Figure 34 on page 349 for a detailed description of descriptor formats.
To permit the queuing and de-queuing of message buffers, ownership of each buffer is allocated to
either the network controller or the host. The OWN bit within the descriptor status information is used
for this purpose.
Setting the OWN to 1 signifies that the network controller currently has ownership of this descriptor
and its associated buffer. Only the owner is permitted to relinquish ownership or to write to any field
in the descriptor entry. A device that is not the current owner of a descriptor cannot assume ownership
or change any field in the entry. A device may, however, read from a descriptor that it does not
currently own. Software should always read descriptor entries in sequential order. When software
finds that the current descriptor is owned by the network controller, the software must not read ahead
to the next descriptor. The software should wait at a descriptor it does not own until the network
controller sets OWN to 0 to release ownership to the software.
Figure 17 on page 81 illustrates the relationship between the receive and transmit descriptor ring base
addresses, the receive and transmit descriptors, and the receive and transmit data buffers for one
receive and one transmit descriptor ring.