Descriptor Rings
BCM5718 Programmer’s Guide
Broadcom
®
January 29, 2016 • 5718-PG108-R
Page 80
• Type—Used internally by the controller. In producer rings it should be set to 0, and in return rings it should
be ignored by host software.
• TCP_UDP_Cksum—Holds the TCP/UDP checksum that the controller calculated for all data following the
IP header given the length defined in the IP header. If the Receive No Pseudo-header Checksum bit is set
(see
“Mode Control Register (offset: 0x6800)” on page 468
) to 1, then the pseudo-header checksum value
is not added to this value. Otherwise, the TCP_UDP_Cksum field includes the pseudo-header in the
controller’s calculation of the TCP or UDP checksum. If the packet is not a TCP or UDP packet, this field
has no meaning. Host software should zero this value in the producer ring descriptors. If the host is capable
of TCP or UDP checksum off load, then host software may examine this field in the return rings to
determine if the TCP or UDP checksum was correct.
• IP_Cksum— Host software should zero this value in the producer ring descriptors. For Receive Return
Ring descriptors, if using IP checksum offload, the host driver software should rely on the Flags bit
IP_CHECKSUM (Flags bit 12) to determine if the IP checksum in the received packet is correct. This field
used to contain the actual IP checksum value but that is not true for the BCM5718 family of controllers.
Only the Flags bit IP_CHECKSUM should be relied on by host driver software as is done by Broadcom
drivers.
• VLAN—Only valid when the VLAN_TAG bit is set. This field contains the 16-bit VLAN ID that was extracted
from an incoming packet that had an IEEE 802.1Q (and IEEE 802.3ac) -compliant header.
• Error_Flags—Contains bits flags that contain error information about an incoming packet that the
descriptor is associated with. The bits in this field are only valid if the FRAME_HAS_ERROR bit is set in the
Flags field in the descriptor. The defined error flags are listed in
.
Table 13: Defined Error Flags for Receive Buffers
Bits
Name
Description
31:9
Reserved
Should be set to 0.
8
GIANT_PKT_RCVD
If set to 1, the received packet was longer than the maximum packet length
value set in the Receive MTU Size register (see
). The data in the received packet was truncated at
the length specified in the Receive MTU Size register.
7
TRUNC_NO_RES
If set to 1, the received packet was truncated because the controller did not
have the resources to receive a packet of this length.
6
LEN_LESS_64
If set to 1, the received packet was less than the required 64 bytes in length.
5
MAC_ABORT
If set to 1, the MAC aborted due to an unspecified internal error while receiving
this packet. The packet could be corrupted.
4
ODD_NIBBLE_RX_MI
I
If set to 1, the received packet contained an odd number of nibbles. Thus,
packet data could be corrupt.
3
PHY_DECODE_ERR If set to 1, while receiving this packet the device encountered an unspecified
frame decoding error. This packet could be corrupted.
This bit is set for valid packets that are received with a dribble nibble. True
alignment errors will be dropped by that MAC and never show up to the driver.
2
LINK_LOST
If set to 1, link was lost while receiving this frame. Therefore, this packet is
incomplete.
1
COLL_DETECT
If set to 1, a collision was encountered while receiving this packet.
0
BAD_CRC
If set to 1, the received packet has a bad Ethernet CRC.