
40
STP2002QFP
Sun Microelectronics
Fast Ethernet, Parallel Port, SCSI (FEPS) - STP2002QFP
5.4.3 Transmit Data StructuresProgramming Restrictions:
• If a packet occupies more than one descriptor, the software must turn
over the ownership of the descriptors to the hardware last-to-first, in
order to avoid race conditions.
• If a packet resides in more than one buffer, the Checksum_Enable,
Checksum_Stuff_Offset and Checksum_Start_Offset fields must have
the samevalues in all the descriptors that were allocated to the packet.
• The hardware implementation relies on the fact, that if a buffer starts
at an odd byte boundary, the DMA state machine can rewind to the
Table 10: Transmit Data Structure Descriptor Layout: Control Word
Field Bits Description
Data buffer size 13:0 Indicates the number of data bytes in the buffer.
All values are legal in a 16-KB range, including
0
Checksum start offset 19:14 Indicates the number of bytes from the first byte
of the packet that should be skipped before the
TCP checksum calculation begins. This field is
only meaningful if the Checksum Enable bit is
set to 1
Checksum stuff offset 27:20 Indicates the byte number from the first byte of
the packet that will contain the first byte of the
computed TCP checksum. This field is only
meaningful if the checksum enable bit is set to 1
Checksum enable 28 If set to 1, the computed TCP checksum will be
stuffed into the packet
End of packet 29 When set to 1, indicates the last descriptor of a
transmit packet
Start of packet 30 When set to 1, indicates the first descriptor of a
transmit packet
Ownership semaphore 31 To turn over ownership, the hardware clears this
bit, and the software sets it
Table 11: Transmit Data Structures: Descriptor Layout: Data Buffer
Pointer
Field Bits Description
Data buffer pointer 31:0 This 32-bit pointer indicates the first data byte of the
transmit buffer