On 31/10/2013 5:24, Sagi Grimberg wrote:
In T10-DIF, when a series of 512-byte data blocks are transferred, each
block is followed by an 8-byte guard. The guard consists of CRC that
protects the integrity of the data in the block, and some other tags
that protects against mis-directed IOs.

Shouldn't that read "logical block length divided by 2**(protection interval exponent)" instead of "512" ? From the SPC-4 FORMAT UNIT section: <quote>For a type 2 protection or a type 3 protection format request, the protection interval exponent determines the length of user data to be transferred before protection information is transferred (i.e., the protection information interval). The protection information interval is calculated as follows: protection information interval = logical block length / 2**(protection interval exponent) where: logical block length is the number of bytes of user data in a logical block (see 4.5) and where protection interval exponent is zero if the short parameter list header (see table 36) is used or the contents of the PROTECTION INTERVAL EXPONENT field if the long parameter list header (see table 37) is used. If the protection information interval calculates to a value that is not an even number (e.g., 520 / 2**3 = 65) or not a whole number (e.g., 520 / 2**4 = 32.5 and 520 / 2**10 = 0.508), then the device server shall terminate the command with CHECK CONDITION status with the sense key set to ILLEGAL REQUEST and the additional sense code set to INVALID FIELD IN PARAMETER LIST.</quote>

Bart.

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to