BCM1250/BCM1125/BCM1125H
User Manual
10/21/02
B r o a d c o m C o r p o r a t i o n
Page
182
Section 7: DMA
Document
1250_1125-UM100CB-R
Example 2 illustrated in
shows preparing an iSCSI packet for transmission. The example has a
packet made up of a single buffer, although split buffers could also be used. Again, software must compute the
pseudo-header sum and put it in the TCP header checksum field. The first descriptor initializes the TCP
checksum and computes the CRC of the iSCSI header information, when this is inserted into the packet it will
be included in the TCP checksum. The second descriptor causes the CRC of the data to be computed and
inserted. In this case the TCP checksum is just continued. The third move adds the TCP header (and pseudo-
header sum) to the checksum and stores the result in the TCP checksum field. (In practice it may be more
effective to just use descriptors 1 and 2 and have the checksum appended after the packet by descriptor 2.
The software can then collect the checksum and do the pseudo-header and TCP header computation.)
Figure 34: Example 2 - Preparing an iSCSI packet
Example 2 can be extended into a more extreme form to also have the Data Mover schedule the packet for
transmission. Assume all iSCSI packets get processed through one channel of the Data Mover and they are
the only packets added to one transmit channel of a MAC. If the CPU prepares a MAC DMA descriptor at the
same time as the data mover descriptors and places the MAC descriptor in the MAC DMA ring (without
incrementing the count) then an additional data move could do a single doubleword copy of the value 1 to the
MAC DMA descriptor count register (using an uncached destination to ensure only one doubleword is written).
This is a somewhat inefficient use of the data mover but has offloaded the CPU from fielding the datamover
interrupt and writing the MAC register.
Example 3 illustrated in
shows preparing a large iSCSI block for fragmentation before
transmission. The example has a packet made up of a single buffer, although split buffers could also be used.
The data mover is used to compute the iSCSI CRCs and the partial TCP checksums that cover the data in
each fragment. The CRCs are inserted into the data block, the checksums are written to a separate array. The
first descriptor resets the checksum for the first fragment and computes and inserts the iSCSI header CRC,
the appended CRC will be included in the TCP sum. The second descriptor resets the CRC for the data
computation, but keeps the checksum running. At the end of the first fragment the TCP checksum is written
into the array (the appended checksum is not included in the CRC so this does not disturb the running CRC).
Descriptor 3 covers the second fragment which needs its own checksum, but continues the CRC (if there were
more fragments this style of descriptor could be repeated). The fourth descriptor covers the final fragment and
will append the datablock CRC and include this CRC in the final checksum. There is then a problem because
Eth
iSCSI Data
Src
Enable CS
Hdr
IP
Hdr
TCP
Hdr
Dst
Reset CS
Prefetch
Src
Dst
Prefetch
Src
Enable CS
Dst
Append CS
Prefetch
Len=iSCSIHdr
Len=Len(data)
Len=TCPHdr
iSCSI
Hdr
iData
CRC
iHdr
CRC
Enable CRC
Reset CRC
Enable CS
Enable CRC
Reset CRC
Append CRC
Append CRC
Содержание BCM1125
Страница 18: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page xviii Document 1250_1125 UM100CB R ...
Страница 28: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page xxviii Document 1250_1125 UM100CB R ...
Страница 515: ...BCM1250 BCM1125 BCM1125H User Manual 10 21 02 Broadcom Corporation Page vii Index Document 1250_1125 UM100CB R ...