sas2r04 section 6.8 SP state machine SATA port selector support question

Sheffield, Robert L robert.l.sheffield at intel.com
Thu Aug 3 17:07:07 PDT 2006


Formatted message: <A HREF="r0608033_f.htm">HTML-formatted message</A>
Attachment #1: <A HREF="r0608033_outlook.jpg">outlook.jpg</A>

Neal and Vicky,
The COMWAKE_Received state machine variable addresses a timing issue
that only applies to the SP0 and SP1 states. Detection of COMWAKE in the
SP3 and SP4 states was added for a different reason.
The COMWAKE_Received state machine variable was added by proposal
04-357r1 (http://www.t10.org/ftp/t10/document.04/04-357r1.pdf
<http://www.t10.org/ftp/t10/document.04/04-357r1.pdf&gt; ), and addresses a
condition resulting from the fact that the duration of the COMWAKE
signal is much shorter than that of the COMINIT signal, and it is
possible that a port selector can respond to a received COMINIT, and the
SAS phy can detect the COMWAKE, even before it has completed
transmission of the COMINIT, and following the transition SP0->SP1, SP1
would erroneously determine the port selector is no longer present,
except for the COMWAKE_Received state machine variable which
communicates prior detection of the COMWAKE detected message.
Detection of COMWAKE was added to SP3 and SP4 to handle corner timing
cases that don't necessarily follow the nominal flow. There are places
in the SATA 2.5 specification of the Port Selector behavior that
indicate a COMINIT received on the phy connected to the SATA device
might cause a COMINIT to be transmitted on the selected phy attached to
the host (granted, this is subject to interpretation). At the time the
COMWAKE detected message text was added to the SP state machine (see
03-273r2: http://www.t10.org/ftp/t10/document.03/03-273r2.pdf), it was
believed that a SATA port selector could, indeed, transmit COMWAKE while
the SP state machine is in the SP3:OOB_AwaitCOMX state or in the
SP4:OOB_COMSAS state. Whether this is the prevailing interpretation of
the Port Selector state machine in SATA 2.5 or not, maintaining the
capability to detect COMWAKE in these two states does not impede
interoperability, and could, perhaps, facilitate interoperability.
Here is one example where during normal operation, both the SATA device
and the SAS phy experience an internal reset at roughly the same time.
In this case, the SATA device wins the race, marginally, and (subject to
interpretation of the Port Selector description in SATA 2.5) the COMINIT
transmitted by the SATA device is "propogated" through the port selector
to the selected SAS phy before the SAS phy completes transmission of
it's COMINIT, but after the SAS phy has transitioned to the
SP0:OOB_COMINIT state.
Then, having both transmitted and received COMINIT in the
SP0:OOB_COMINIT state, the SP state machine transitions to the
SP4:OOB_COMSAS state, where it receives the COMWAKE transmitted by the
port selector in response to the COMINIT transmitted by the SAS phy.
The attached sequence diagram shows the interaction.
Best regards,
Bob
________________________________
From: owner-t10 at t10.org [mailto:owner-t10 at t10.org] On Behalf Of Chang,
Neil
Sent: Tuesday, August 01, 2006 9:49 AM
To: Duerk, Vicky P; t10 at t10.org
Subject: RE: sas2r04 section 6.8 SP state machine SATA port selector
support question
Thanks to those who responded - it seems like the question was
ambiguous. 
Per Serial ATA 2.5 specification Port Selector section, the behavior of
presence of SATA Port Selector is to transmit COMWAKE before transmit
COMINIT from the port selector. It is clear that an attached SATA Port
Selector can be determined if received COMWAKE before receiving COMINIT
which is what described in the SP0:OOB_COMINIT state and the
SP1:OOB_AwaitCOMX state.
SP4:OOB_COMSAS may be entered after detected and transmitted COMINIT.
Therefore, can a SATA Port Selector be determined in SP4 when receiving
COMWAKE? As it's pointed out, similar question applies to
SP3:OOB_AwaitCOMINIT_Sent state where it has received COMINIT already.
Regards,
Neil Chang
________________________________
From: Duerk, Vicky P 
Sent: Monday, July 31, 2006 11:06 PM
To: Chang, Neil; t10 at t10.org
Subject: RE: sas2r04 section 6.8 SP state machine SATA port selector
support question
Neil,
COMWAKE_Received state machine variable indicates "whether a COMWAKE
detected message was received in the SP0:OOB_COMINIT state or the
SP1:OOB_AwaitCOMX state since the last time the SP0:OOB_COMINIT state
was entered".  This variable is used in the SP1 state in the hot-plug
timer timeout case to transition to SP0.  
6.8.3.3.2 Transition SP1:OOB_AwaitCOMX to SP0:OOB_COMINIT
This transition shall occur if the Hot-Plug Timeout timer expires.
If the COMWAKE_Received state machine variable is set to zero and the
ATTACHED SATA PORT SELECTOR bit is
set to one in the SMP DISCOVER response (see 10.4.3.5) and the SMP
DISCOVER LIST response (see
10.4.3.12.3), the state machine shall, before the transition:
a) set the ATTACHED SATA PORT SELECTOR bit to zero in the SMP DISCOVER
response and the SMP DISCOVER LIST response; and
b) send a SATA Port Selector Change confirmation to the link layer.
This particular sentence that you mentioned in the first paragraph of
your email does not prohibit COMWAKE from being detected in some other
states other than SP0 and SP1.	In fact, besides the SP4: OOB_COMSAS
state that you discovered that does receive "COMWAKE detected message",
there is another state SP3: AwaitCOMINIT_Sent state that respond to
COMWAKE detected message as well.  The difference is SP3 and SP4 does
not need to maintain the extra COMWAKE_Received state machine variable.
I don't see any inconsistency here.
Vicky
________________________________
From: owner-t10 at t10.org [mailto:owner-t10 at t10.org] On Behalf Of Chang,
Neil
Sent: Monday, July 31, 2006 6:43 PM
To: t10 at t10.org
Subject: sas2r04 section 6.8 SP state machine SATA port selector support
question
6.8 SP (phy layer) state machine
6.8.1 SP state machine overview
...
If the phy supports SATA port selectors, the SP state machine shall
maintain a COMWAKE_Received state machine variable to indicate whether a
COMWAKE detected message was received in the SP0:OOB_COMINIT state or
the SP1:OOB_AwaitCOMX state since the last time the SP0:OOB_COMINIT
state was entered,...
Later in 6.8.3.6 SP4:OOB_COMSAS state, it states (in page 210),
Upon entry into this state, this state shall send a Transmit COMSAS
message to the SP transmitter.
This state waits for receipt of a COMSAS Transmitted message and/or a
COMSAS Detected message.
If the phy supports SATA port selectors, the ATTACHED SATA PORT SELECTOR
bit is set to zero in the SMP
DISCOVER response (see 10.4.3.5), and this state receives a COMWAKE
Detected message, this state shall:
a) set the ATTACHED SATA PORT SELECTOR bit to one in the SMP DISCOVER
response; and
b) send a SATA Port Selector Change confirmation to the link layer.
Question: It states earlier that COMWAKE_Received state machine variable
shall be maintained to indicate that COMWAKE_detected message was
received in SP0 and SP1 states. But later in SP4:OOB_COMSAS state, it
indicates that it could receive COMWAKE detected message. Is it just
specification inconsistence? Or any comments are appreciated.
Thanks,
Neil Chang



More information about the T10 mailing list