Subject: Question On R2T Behaviour?

From: "Suresh Tanjore" <[email-masked]>
Date: Fri, 16 Nov 2001 09:39:17 -0800

Hi all,

On page 75 of iSCSi 0.8 revision

	" The data length of the DATA PDU MUST *not exceed* the desired
	data transer length specified in the R2T. If the R2T is answered
	with a sequence of data PDUs the buffer offset and Length
	must be within the range of those specfied by R2T, the last PDU
	SHOULD have the F bit set to 1. The data-out PDU ordering is goverened
	by  DataPDUInOrder."

My question is if the data length of the DATA PDU is less than
the desired data transfer length and the F bit is set, what should be the
behaviour of the target. For the sake of this discussion let us
assume DataPDUInOrder to be set to Yes.

	1. It looks intutive that target may send another R2T with different
	   sequence number and collect the data initially that the host
	   was not able to send for the previous R2T request.

	Or

	2. It is an error that need to be detected by target that the host was not
	   able to fully satisfy the R2T request sent by the target in the first
place.

Please let me know what is the right behaviour and should this be documented
in the
specification if it is not already documented. If it is documented may be i
missed
reading this, please point to me where it is defined.

Thanks
sureshtk

---

From: "Anshul Chadda" <[email-masked]>
Date: Fri, 16 Nov 2001 17:58:39 -0500

Hi Suresh:
I believe that the target can take step 1. But then the problem might still
prevail. Why?? If the initiator wasn't able to send Data for the first R2T,
there is no guarantee that it will be able to send the same data (that it
couldn't send before) for the second R2T. So, the target cannot try sending
R2T asking for the same data infinitely.

I don't think it is an error if the initiator is not able to send the whole
data, involved in an R2T, as long as it sets the F bit to 1 in the final
Data-Out PDU (mentioned in Step 2).

I would assume that the target has an option to take care of this behavior
by sending SCSI Response PDU with U-bit set and the Residual Count set to a
data value that it was not able to receive.This step can be taken by the
target as a conservative one and can serve as a fallback solution in case
step 1 doesn't work.

Anshul