Terminate Immediate Sequence X3T9.2/88-158R0 TO: John Lohmeyer FROM: Steve Goldman DATE: December 5, 1988 The terminate immediate sequence involves the transmission of two special messages and is intended to give initiators an increased degree of real-time control when communicating with SCSI target devices. Specifically, READ or WRITE commands which involve long transfer lengths may be terminated before the transfer count has been exhausted without requiring the entire transfer to be repeated later as with the abort message, i.e. blocks already successfully read from or written to the medium need not be re-transferred. This facilitates initiators which cache data on the host computer or host adapter to initiator long background read or write operations while still providing a means of terminating the operation before all data has been read or written in order to initiate a foreground read or write operation due to a cache miss or an FUA read or write. TERMINATE IMMEDIATE This message is sent from the initiator to the target during a read or write operation to indicate that the current I/O process should be terminated as expeditiously as possible. Upon receiving this message the target may continue transferring data but should reduce the transfer length to a value which allows the current command to be terminated as soon as possible. After the last byte of the data phase for that command the target shall switch to message in phase and send the REPORT TRANSFER LENGTH message. The target shall then switch to the STATUS phase and terminate the command in the normal way. The status byte shall indicate the success or failure of the operation for the blocks written to the medium or transferred to the initiator. REPORT TRANSFER LENGTH This message is sent by the target for commands which have been terminated due to a TERMINATE IMMEDIATE message in order to indicate to the initiator the actual number of logical blocks written to the medium in the case of a write operation, or transferred to the initiator in the case of a read operation. After sending this message, the target shall then switch to the STATUS phase and terminate the command in the normal way. The status byte shall indicate the success or failure of the operation for the blocks written to the medium or transferred to the initiator.