From: Douglas Gilbert <dougg@torque.net>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: Jens Axboe <axboe@suse.de>,
James Bottomley <James.Bottomley@SteelEye.com>,
SCSI Mailing List <linux-scsi@vger.kernel.org>,
linux-ide@vger.kernel.org
Subject: Re: libata, SCSI and storage drivers
Date: Fri, 27 May 2005 16:45:38 +1000 [thread overview]
Message-ID: <4296C212.4030703@torque.net> (raw)
In-Reply-To: <42968AC9.60705@pobox.com>
Jeff Garzik wrote:
> Jens Axboe wrote:
>
>> On Tue, May 24 2005, Jeff Garzik wrote:
>>
>>> Jens Axboe wrote:
>>>
>>>> On Tue, May 24 2005, Jeff Garzik wrote:
>>>>
>>>>> I can describe how this will look when libata is divorced from
>>>>> SCSI, if you would like, too...
>>>>
>>>>
>>>> I was beginning to dispair you had given up that plan...
>>>
>>>
>>> hehe, nope. I promised Linus, and I plan to keep my promise :)
>>
>>
>>
>> You promised me, too :)
>>
>>
>>> I know how to do it. Internally things have been kept as separate as
>>> possible from the SCSI layer.
>>
>>
>>
>> We should start a list of items that could potentially be moved to the
>> block layer that libata currently uses.
>
>
>
> Here are the two broad categories of things that immediately come to mind.
>
>
> 1. Hardware in pre-production right now can do SAS or SATA on the same
> card. So, real soon, a driver will need to do both SCSI and ATA
> depending on runtime conditions.
>
> The SCSI transport class is a very nice way to connect low-level drivers
> and the class drivers (disk/cdrom/tape/...). It works well with the
> device model, and is modular in just the right location.
>
> I would like to develop ATA transport class(es). In order to work well
> with SATA/SAS hardware, there will need to be at least one.
>
> And as I hoped you have guessed..... the ATA transport class should be
> a child of the block layer, not the SCSI layer.
Jeff,
Yes, the SAS HBAs that I'm aware of can connect to
SATA I/II disks "directly" on their phys.
So here are two scenarios for connecting SATA disks:
a)
SAS HBA < -------------------------> SATA disk
b)
SAS HBA <------>SAS_expander<------> SATA disk
In a) the interconnect is SATA. Still it is hard
to believe that the SAS HBA LLD would belong to
anything other than the SCSI subsystem (since
SAS HBAs come with 4 or 8 phys, others of which could
be in scenario b) and/or connected to SAS disks).
Hence the initiator_ports/phys/target_ports on and
seen by that SAS HBA should (also) have SAS transport
classes.
When a SAS HBA phy is not connected to anything is it
a member of a SAS transport class or a ATA transport
class (or both)?
In scenario b) the left interconnect is SAS and the
right interconnect is SATA. The SAS_expander contains
the STP<->SATA bridging function (and, for sake of
argument, no SCSI-ATA Translation (SAT) layer).
Would scenario b) also have a ATA transport
class? I'll assume it does. To be discovered it also
needs a SAS transport class. Larger enclosures are
likely to be amplifications of scenario b). The presence
of the SATA disk in scenario b) will be discovered via
the SAS SMP (i.e. talking to the SAS_expander) or via
the SES protocol (i.e. a SCSI Enclosure Services target
running near the SAS_expander). Either way if there are
a lot of SATA disks then they are likely to be held
in their initialization sequence to stop them spinning
up all at once. SAS transport intervention may be
required (staggered timers are another possibility).
Now I may be wrong but I think that one of the SAS HBAs
that I have read about that looks (externally) like
scenario a) but is actually scenario b). In other words
the SAS_expander is silicon on the HBA and it is not
controlled via the PCI bus, but rather by SMP.
This suggests to me we would need an ordered sequence of
transport classes. I really wonder about trying to model
this level of complexity in sysfs, plus the nightmare of
keeping state data of (topologically) distant nodes up
to date. At some point one needs to supply a management
pass through and hand the problem over to the user
space. The question is, at what point.
There are already FCP enclosures filled with SATA disks
on the market so this problem in not unique to SAS.
However they have (I presume) a SAT layer in their
FC enclosures so the OS thinks it is taking to SCSI
disks.
Doug Gilbert
next prev parent reply other threads:[~2005-05-27 6:45 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-23 20:15 [PATCH] libata: device suspend/resume Jeff Garzik
2005-05-23 20:41 ` James Bottomley
2005-05-23 20:45 ` Jeff Garzik
2005-05-23 22:10 ` James Bottomley
2005-05-24 6:21 ` Jens Axboe
2005-05-24 6:53 ` Jeff Garzik
2005-05-24 7:06 ` Hannes Reinecke
2005-05-24 7:08 ` Jens Axboe
2005-05-24 7:16 ` Jeff Garzik
2005-05-24 7:07 ` Jens Axboe
2005-05-24 7:10 ` Jeff Garzik
2005-05-24 7:13 ` Jens Axboe
2005-05-27 2:49 ` libata, SCSI and storage drivers Jeff Garzik
2005-05-27 6:45 ` Douglas Gilbert [this message]
2005-05-27 14:41 ` Luben Tuikov
2005-05-24 7:14 ` [PATCH] libata: device suspend/resume Hannes Reinecke
2005-05-24 7:15 ` Jens Axboe
2005-05-24 7:18 ` Jeff Garzik
2005-05-24 10:17 ` Douglas Gilbert
2005-05-24 17:10 ` Jeff Garzik
2005-05-24 7:59 ` Jens Axboe
2005-05-24 8:21 ` Jeff Garzik
2005-05-24 8:51 ` Jens Axboe
2005-05-24 16:37 ` Jeff Garzik
2005-05-25 9:29 ` Jens Axboe
2005-05-25 23:40 ` Guennadi Liakhovetski
2005-05-26 1:05 ` Jeff Garzik
2005-05-26 5:57 ` Jens Axboe
2005-05-26 22:56 ` Bartlomiej Zolnierkiewicz
2005-05-27 6:54 ` Jens Axboe
2005-05-27 2:01 ` Benjamin Herrenschmidt
2005-05-27 6:55 ` Jens Axboe
2005-05-24 13:48 ` Luben Tuikov
2005-05-24 17:29 ` Jeff Garzik
2005-05-24 13:05 ` Luben Tuikov
2005-05-27 2:54 ` Jeff Garzik
2005-05-24 16:27 ` Mark Lord
2005-05-24 16:33 ` Mark Lord
2005-05-24 16:04 ` Mark Lord
-- strict thread matches above, loose matches on Subject: below --
2005-05-27 12:42 libata, SCSI and storage drivers James.Smart
2005-05-27 14:26 James.Smart
2005-05-27 17:45 James.Smart
2005-05-27 18:05 ` Jeff Garzik
2005-05-27 19:04 ` James Bottomley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4296C212.4030703@torque.net \
--to=dougg@torque.net \
--cc=James.Bottomley@SteelEye.com \
--cc=axboe@suse.de \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).