English
Language : 

K60P100M100SF2RM Datasheet, PDF (1199/1809 Pages) Freescale Semiconductor, Inc – K60 Sub-Family Reference Manual
Chapter 44 10/100-Mbps Ethernet MAC (ENET)
• For ICMP the checksum is calculated over the complete ICMP datagram (i.e. without
IP header).
• For TCP and UDP the checksums contain the header and data sections and values
from the IP header, which can be seen as a pseudo header that is not actually present
in the datastream.
Table 44-76. IPv4 Pseudo Header for Checksum calculation
3
1
3
0
2
9
2
8
2
7
2
6
2
5
2
4
2
3
2
2
2
1
2
0
1
9
1
8
1
7
1
6
1
5
1
4
1
3
1
2
1
1
1
0
9
8
7
6
5
4
3
2
1
0
Source address
Destination Address
Zero
Protocol
TCP/UDP length
Table 44-77. IPv6 Pseudo Header for Checksum Calculation
3
1
3
0
2
9
2
8
2
7
2
6
2
5
2
4
2
3
2
2
2
1
2
0
1
9
1
8
1
7
1
6
1
5
1
4
1
3
1
2
1
1
1
0
9
8
7
6
5
4
3
2
1
0
Source address
Destination Address
TCP/UDP length
Zero
Next header
The TCP/UDP length value is the length of the TCP or UDP datagram, which is equal to
the payload of an IP datagram. It is derived by subtracting the IP header length from the
complete IP datagram length that is given in the IP header (IPv4) or directly taken from
the IP header (IPv6). The protocol field is the corresponding value from the IP header and
Zero is filled with zeroes.
For IPv6 the complete 128-bit addresses are considered. The next header value identifies
the upper layer protocol (TCP or UDP) and may differ from the IPv6 header's actual next
header value if extension headers are inserted before the protocol header.
The checksum calculation uses 16-bit words in network byte order: The first byte sent/
received is the MSB, and the second byte sent/received is the LSB of the 16-bit value to
add to the checksum. If the frame ends on an odd number of bytes, a zero byte is
appended for checksum calculation only (not actually transmitted).
44.4.8.2 Additional Padding Processing
According to IEEE 802.3, any Ethernet frame must have a minimum length of 64 octets.
K60 Sub-Family Reference Manual, Rev. 6, Nov 2011
Freescale Semiconductor, Inc.
1199