Unit attention on FCP devices

Edward A. Gardner eag at ophidian.com
Mon Aug 28 08:28:13 PDT 2000


* From the T10 Reflector (t10 at t10.org), posted by:
* "Edward A. Gardner" <eag at ophidian.com>
*
I recently encountered a question about the operation of unit attention on
FCP devices.  While I think I know how it has to work, I cannot find a clear
statement of this anywhere (SAM, SAM-2, FCP, FCP-2).

The specific question is what event clears a unit attention condition on an
FCP device (or more generally on any device that supports autosense).
Consider the following events:

1.  An initiator is accessing a LUN on an FCP target.

2.  A unit attention condition occurs on the LUN during some period when no
commands or tasks are outstanding to it.  Perhaps someone changes the media
on a removable media device.  The event specifically does not disturb the
connection (process login) between the initiator and target.

3.  The initiator sends a command (NACA=0) to the target.  This command
encounters the unit attention condition, the target returns CHECK CONDITION
and autosense data describing the unit attention condition.  Note that the
CA condition that occurs by returning CHECK CONDITION is immediately cleared
by the simultaneous return of autosense data (I would like to say that no CA
condition occurs, but that isn't SAM terminology).

At this time, has the return of autosense data describing the unit attention
condition cleared the unit attention, or does it still exist until the
initiator issues an explicit REQUEST SENSE to clear it?

On the one hand I believe it is necessary that the unit attention condition
still exist until an explicit REQUEST SENSE.  Otherwise commands that are in
flight, issued before the initiator was aware of the unit attention
condition, may be executed against the wrong media (or against whatever
change the unit attention was reporting).

On the other hand the words in SAM and SAM-2 appear to suggest that the unit
attention condition will be cleared by the return of autosense data.  SAM
and SAM-2 use the phrase "if a request for sense data is received" (clause
5.6.5).  One can interpret autosense as a request for sense data.  Clause
5.6.4.2 states "The return of sense data in this way [autosense] is
equivalent to an explicit command from the application client requesting
sense data".  That is, returning autosense data is equivalent to a REQUEST
SENSE, and REQUEST SENSE clears unit attention.

The one thing I have no doubt about is that the current wording describing
unit attention handling is ambiguous and confusing; I intend to generate
some comments to clarify it.  But first I want to make certain whether FCP
devices work the way I think they do.

Edward A. Gardner               eag at ophidian.com
Ophidian Designs                719 593-8866 voice
1262 Hofstead Terrace           719 593-8989 fax
Colorado Springs, CO  80907     719 210-7200 cell

*
* 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