From: Brian King <brking@us.ibm.com>
To: Luben Tuikov <luben_tuikov@adaptec.com>
Cc: Jeff Garzik <jgarzik@pobox.com>,
Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>,
linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [PATCH 1/2] libata: Remove dependence on host_set->dev for SAS
Date: Thu, 27 Oct 2005 11:05:21 -0500 [thread overview]
Message-ID: <4360FAC1.8020409@us.ibm.com> (raw)
In-Reply-To: <435EB656.1040502@adaptec.com>
Luben Tuikov wrote:
> Would it be a good idea to abstract most of this in
> say something like
>
> struct satl_device_struct {
> -- data... ;
>
> /* The registering entity calls this for SATL to translate
> to an ATA task(s) and execute. Filled in by the SATL Layer. */
> int (*execute_scsi_task)(struct satl_device_struct *, struct scsi_cmnd *);
>
> /* SATL layer calls this to send an ata_task to the device.
> Filled in by the registering entity. */
> int (*execute_ata_task)(struct satl_device_struct *, struct ata_task *);
>
> -- recovery methods common to SATA-over-anything; filled in by registering
> \ entity
> };
>
> (ata task to be properly constructed: FIS, sg lists, etc.)
>
> Then libata-scsi would only have to export two (2) functions:
>
> int satl_register_device(struct satl_device_struct *);
> void satl_unregister_device(struct satl_device_struct *);
>
> EXPORT_SYMBOL_GPL(satl_register_device);
> EXPORT_SYMBOL_GPL(satl_unregister_device);
Where would you be calling satl_register_device in your SAS class?
It looks like this would force libata to be the one to attach the ULD,
which would also force it to create a separate scsi_host for each
device, which is something I wanted to avoid. I think you really need a
libata API that the LLDD can call from its queuecommand function
to translate and send a command, which then calls back into the LLDD
to send the FIS to the hardware. This allows for all SAS/SATA devices
under the same HBA to show up under the same scsi_host.
Brian
--
Brian King
eServer Storage I/O
IBM Linux Technology Center
next prev parent reply other threads:[~2005-10-27 16:05 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-03 21:56 [RFC 0/2] libata: support SATA devices on SAS HBAs Brian King
2005-10-03 21:58 ` [RFC 1/2] libata: configurable host_set lock Brian King
2005-10-03 21:58 ` [RFC 2/2] libata: support SATA devices on SAS HBAs Brian King
2005-10-04 9:56 ` [RFC 0/2] " Jeff Garzik
2005-10-04 10:22 ` Bartlomiej Zolnierkiewicz
2005-10-04 20:56 ` Bartlomiej Zolnierkiewicz
2005-10-05 20:59 ` Jeff Garzik
2005-10-24 22:17 ` [PATCH " Brian King
2005-10-24 22:19 ` [PATCH 1/2] libata: Remove dependence on host_set->dev for SAS Brian King
2005-10-25 17:53 ` Jeff Garzik
2005-10-25 19:30 ` Brian King
2005-10-25 19:43 ` Jeff Garzik
2005-10-25 22:48 ` Luben Tuikov
2005-10-27 16:05 ` Brian King [this message]
2005-10-27 20:15 ` Luben Tuikov
2005-11-24 0:53 ` Douglas Gilbert
2005-11-24 1:07 ` Jeff Garzik
2005-11-24 8:12 ` Bartlomiej Zolnierkiewicz
2005-12-02 2:05 ` Jeff Garzik
2005-12-02 8:07 ` Bartlomiej Zolnierkiewicz
2005-12-02 10:28 ` Douglas Gilbert
2005-12-02 10:48 ` Jeff Garzik
2005-11-29 22:13 ` Brian King
2005-10-24 22:20 ` [PATCH 2/2] libata: Add support for SATA attachment to SAS adapters Brian King
2005-10-25 17:58 ` Jeff Garzik
2005-10-25 12:59 ` [PATCH 0/2] libata: support SATA devices on SAS HBAs Luben Tuikov
2005-10-25 13:39 ` Brian King
2005-10-25 13:40 ` Luben Tuikov
2005-10-25 13:53 ` Brian King
2005-10-25 14:08 ` Luben Tuikov
2005-10-25 14:27 ` Brian King
2005-10-25 17:51 ` Jeff Garzik
2005-10-25 17:57 ` [RFC " Brian King
2005-10-25 18:07 ` Jeff Garzik
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=4360FAC1.8020409@us.ibm.com \
--to=brking@us.ibm.com \
--cc=bzolnier@gmail.com \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=luben_tuikov@adaptec.com \
/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).