Re: sg driver and Fedora Core 2

Douglas Gilbert
2004-06-07T08:57:07Z

Alan Cox wrote:
> On Sun, May 30, 2004 at 08:37:14PM +1000, Douglas Gilbert wrote:
>
>>configuring the SAS domain. Expanders are SAS devices but
>>not SCSI devices (i.e. they are neither initiators nor
>>targets ***). It seems obvious that the management of a SAS
>>domain should be done from the user space. Only those
>>expanders and devices directly attached to a SAS Host Bus
>>Adapter should automatically be visible.
>
>
> Is there any reason that the SAS domain should in itself be a character
> device file. I've always thought of it as a network and anticipated
> a network layer interface for such things. That might just be my background
> however.

Alan,
In the SCSI parallel world the "domain" is usually
called the "bus" which is a set of targets and one or more
initiators and the ribbon (or external) cable that
interconnect them.

In SAS the "domain" is a little more rubbery. After wide
links are taken into account, there cannot be multiple
paths between scsi devices within one SAS domain (i.e. "no
loops"). An expander is part of the service interconnect
subsystem of a _single_ SAS domain (i.e. it can't be shared).
This means that expanders can be wired incorrectly.
Even simple interconnects need some thought:

| SAS 2 |
| port HBA |
--------------
| |
| |
| |
| |
-------------
| SAS dual |
|ported disk|

Is this a (2 phy) wide-link, single SAS domain or two SAS
domains? On current indications it is two SAS domains since
dual ported SAS disks have different SAS addresses on each
port. [The fact that the SAS HBA has the same SAS addresses
on both phys only meets half the requirement for a wide link.]

See SAS Quiz question 1 (then its answer) in the pdfs at:
http://www.scsita.org/aboutscsi/sas/tutorials.html
for a more complex scenario.

Detecting and explaining to a user why his/her SAS domain(s)
is incorrectly wired will be an interesting challenge.

So it wasn't the SCSI domain that I was proposing should
be a char (or network) device file. It was the SMP target
port inside each expander that is used for discovery,
configuration and statistics that needs a packet based
initiator driver/interface (like the sg driver). The concept
of a SAS domain I would rather leave for a user space
program.

Doug Gilbert