SAT TEST UNIT READY command translation

Sheffield, Robert L robert.l.sheffield at intel.com
Mon Aug 15 11:56:00 PDT 2005


* From the T10 Reflector (t10 at t10.org), posted by:
* "Sheffield, Robert L" <robert.l.sheffield at intel.com>
*
Good point. We should discuss this at Monday's SAT WG meeting in
Boulder.
We could add it as a new agenda item, or we could discuss it in the
context of 05-226.

There is a basic problem here - ATA drives do not support the equivalent
of the SCSI "STOPPED" state.
The current definition of TEST UNIT READY in SAT assumes the ATA STANDBY
state is the equivalent of the SCSI STOPPED state. But, in fact, it is
not because a media access command issued to the drive will cause the
drive to enter the ACTIVE state and the command will execute
successfully, although with added latency required to transition from
the ATA STANDBY state to the ATA ACTIVE state. Whereas when a SCSI drive
is in the STOPPED state, a media access command will cause a CHECK
CONDITION status with a sense key set to NOT READY and the additional
sense code set to LOGICAL UNIT NOT READY INIITIALIZING COMMAND REQUIRED.

The SAT definition for the TEST UNIT READY command should probably be
modified to return GOOD status if the ATA CHECK POWER MODE command
completes successfully, regardless of which power mode is returned.

There is also a problem with the definition of the START STOP UNIT
command in 05-226r2. In this proposal, we have a condition where the
START bit is asserted, and because the READ VERIFY command failed the
SAT returned CHECK CONDITION status, NOT READY sense key, and LOGICAL
UNIT NOT READY - INITIALIZING COMMAND REQUIRED additional sense code.
This is incongruous because it is a response to the "initializing
command" an application client would issue to resolve the condition
reported in the first place. 

I would suggest that instead, in the definition of the START STOP UNIT
command with the START bit asserted, if the ATA READ VERIFY command
fails for any reason, the SAT should terminate the command with CHECK
CONDITION status with the sense key set to NOT READY, and the additional
sense code set to LOGICAL UNIT NOT READY, MANUAL INTERVENTION REQUIRED.

This has the result that a SCSI logical unit represented by the SATL
will never be in the STOPPED state. So, even though the SATL processed a
START STOP UNIT command with START=0, the device as perceived by the
SCSI application client will be in the SCSI STANDBY state. The response
to TEST UNIT READY (assuming no errors) should be GOOD status.

Question: does this cause problems for any SCSI applications - that a
SAT logical unit will never go into the STOPPED state?

Regards,
Bob Sheffield


-----Original Message-----
From: Douglas Gilbert [mailto:dougg at torque.net] 
Sent: Friday, August 12, 2005 7:43 PM
To: Sheffield, Robert L
Cc: t10 at t10.org; jgarzik at pobox.com; mark_evans at maxtor.com
Subject: Re: SAT TEST UNIT READY command translation

Sheffield, Robert L wrote:
> There is a proposal in-process to redefine the Test Unit Ready
> translation in SAT:
> ftp://ftp.t10.org/t10/document.05/05-226r2.pdf
> 
> See the SAT WG agenda: http://www.t10.org/ftp/t10/sat-agnd.htm

Robert,
Those references do not mention the TEST UNIT READY command
but the closely related START STOP UNIT command.

SAT revision 5 ties the implementations of those two commands
together, so perhaps Mark Evan's proposal to change
the START STOP UNIT command in SAT could be extended to
cover the TEST UNIT READY command (and REQUEST SENSE, see
below).

> In this proposal - if the device is in standby the SATL issues the
> command anyway. If it completes without error - GOOD status is
returned.

If you are proposing that TEST UNIT READY still translates
to the Check Power Mode ATA command and returns a SCSI
status of GOOD unless that ATA command fails, then that
seems reasonable.

I just noticed that REQUEST SENSE in SAT (rev 05) does
yield a sense key of NO SENSE and an additional sense
code of LOW POWER CONDITION ON when the ATA disk is
in Standby power mode. Perhaps a note could be added
about how the SAT layer comes to this conclusion (i.e.
issues a Check Power Mode ATA command).

<snip>

cc-ed to Mark Evans

Doug Gilbert
*
* For T10 Reflector information, send a message with
* 'info t10' (no quotes) in the message body to majordomo at t10.org





More information about the T10 mailing list