09.12.2012 Views

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

RM0090: Reference manual - STMicroelectronics

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Ethernet (ETH): media access control (MAC) with DMA controller <strong>RM0090</strong><br />

type (Ethernet Type field) and the IP header version, or when the received frame does not<br />

have enough bytes, as indicated by the IPv4 header’s Length field (or when fewer than 20<br />

bytes are available in an IPv4 or IPv6 header). The receive checksum offload also identifies<br />

a TCP, UDP or ICMP payload in the received IP datagrams (IPv4 or IPv6) and calculates the<br />

checksum of such payloads properly, as defined in the TCP, UDP or ICMP specifications. It<br />

includes the TCP/UDP/ICMPv6 pseudo-header bytes for checksum calculation and checks<br />

whether the received checksum field matches the calculated value. The result of this<br />

operation is given as a Payload Checksum Error bit in the receive status word. This status<br />

bit is also set if the length of the TCP, UDP or ICMP payload does not match the expected<br />

payload length given in the IP header. As mentioned in TCP/UDP/ICMP checksum on<br />

page 919, the receive checksum offload bypasses the payload of fragmented IP datagrams,<br />

IP datagrams with security features, IPv6 routing headers, and payloads other than TCP,<br />

UDP or ICMP. This information (whether the checksum is bypassed or not) is given in the<br />

receive status, as described in the RDES0: Receive descriptor Word0 section. In this<br />

configuration, the core does not append any payload checksum bytes to the received<br />

Ethernet frames.<br />

As mentioned in RDES0: Receive descriptor Word0 on page 957, the meaning of certain<br />

register bits changes as shown in Table 163.<br />

Table 163. Frame statuses<br />

Bit 18:<br />

Ethernet frame<br />

Bit 27: Header<br />

checksum error<br />

Receive frame controller<br />

Bit 28: Payload<br />

checksum error<br />

0 0 0<br />

1 0 0<br />

1 0 1<br />

1 1 0<br />

1 1 1<br />

0 0 1<br />

0 1 1<br />

0 1 0 Reserved<br />

If the RA bit is reset in the MAC CSR frame filter register, the MAC performs frame filtering<br />

based on the destination/source address (the application still needs to perform another level<br />

of filtering if it decides not to receive any bad frames like runt, CRC error frames, etc.). On<br />

detecting a filter-fail, the frame is dropped and not transferred to the application. When the<br />

filtering parameters are changed dynamically, and in case of (DA-SA) filter-fail, the rest of<br />

923/1416 Doc ID 018909 Rev 3<br />

Frame status<br />

The frame is an IEEE 802.3 frame (Length<br />

field value is less than 0x0600).<br />

IPv4/IPv6 Type frame in which no checksum<br />

error is detected.<br />

IPv4/IPv6 Type frame in which a payload<br />

checksum error (as described for PCE) is<br />

detected<br />

IPv4/IPv6 Type frame in which IP header<br />

checksum error (as described for IPCO HCE)<br />

is detected.<br />

IPv4/IPv6 Type frame in which both PCE and<br />

IPCO HCE are detected.<br />

IPv4/IPv6 Type frame in which there is no IP<br />

HCE and the payload check is bypassed due<br />

to unsupported payload.<br />

Type frame which is neither IPv4 or IPv6<br />

(checksum offload bypasses the checksum<br />

check completely)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!