From: Brian King <brking@us.ibm.com>
To: James Bottomley <James.Bottomley@SteelEye.com>
Cc: jgarzik@pobox.com, linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [PATCH 1/2] scsi: Add scsi_device max_cmd_len
Date: Tue, 28 Mar 2006 22:42:03 -0600 [thread overview]
Message-ID: <442A101B.4070209@us.ibm.com> (raw)
In-Reply-To: <1143591144.3353.55.camel@mulgrave.il.steeleye.com>
James Bottomley wrote:
> Well, no, not scsi transport; I think just a general transport ... see
> the raid_class for an example of one of these (albeit not very related
> to what you want to do, I'm afraid).
>
> technically, you can have multiple transports per device, even with SCSI
> ones. It's just convenient to simplify the single attachement case
> since that's the predominant one.
>
> The key is in the match function. Given a generic device, you have to
> know how to verify its a device of the type you want.
From what I understand, it looks like I should be creating a sata_class
transport of sorts, which would attach to scsi_hosts that support SATA
and would contain SATA host related attributes. It would also provide
APIs such as sata_dev_alloc, sata_dev_add, similar to sas_phy_alloc,
and sas_phy_add, which would be called by external users to attach
SATA devices to the upper layers. sata_dev_add would result in
the device getting hooked into libata and getting added to scsi core,
etc. There could then also be per-device hooks/attributes in the
sata_class transport as appropriate.
However, since scsi core is the one that checks max_cmd_len,
scsi core would somehow need to be able to poke into the sata host
transport attribute to decide whether or not to accept the command.
Probably an addition to struct scsi_transport_template?
This is quite a change from the patchset I have been carrying
for the past 5 months or so to add SATA support to ipr. The
current ipr patch to add this support can be found here:
http://marc.theaimsgroup.com/?l=linux-scsi&m=114263741229458&w=2
It requires no change to scsi core other than the patch we are
discussing (which could technically also be done in libata),
and requires minimal libata changes. I'm happy to start coding
up a sata_class, but is there any chance of this being a phase
2 solution, and for the interim we proceed with something closer
to what I have been submitting to the list for the past 5 months?
I'm happy to drop the patch that started this thread if that helps.
Would you be OK with the ipr patch in the URL above as an interim
solution?
Thanks,
Brian
--
Brian King
eServer Storage I/O
IBM Linux Technology Center
next prev parent reply other threads:[~2006-03-29 4:42 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-28 22:17 [PATCH 1/2] scsi: Add scsi_device max_cmd_len Brian King
2006-03-28 22:29 ` James Bottomley
2006-03-28 22:38 ` Brian King
2006-03-28 22:49 ` James Bottomley
2006-03-29 0:03 ` Brian King
2006-03-29 0:12 ` James Bottomley
2006-03-29 4:42 ` Brian King [this message]
2006-03-29 23:22 ` Jeff Garzik
2006-03-29 9:11 ` Christoph Hellwig
2006-03-29 14:15 ` Brian King
2006-03-29 15:05 ` Christoph Hellwig
2006-03-29 23:19 ` Jeff Garzik
2006-03-30 16:39 ` Brian King
2006-03-30 16:42 ` Brian King
2006-04-04 9:25 ` Jeff Garzik
2006-04-07 13:36 ` Brian King
2006-04-01 10:31 ` Stefan Richter
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=442A101B.4070209@us.ibm.com \
--to=brking@us.ibm.com \
--cc=James.Bottomley@SteelEye.com \
--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).