Skip to content

libata: support SATA devices on SAS HBAs

Brian King linux-ide linux-scsi 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest0 of 2 patches 7 repliesIn review

Patches in v1 No applies recorded yet

None of the 2 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] libata: support SATA devices on SAS HBAs

The following patches enhance libata to allow SAS device drivers to utilize libata to talk to SATA devices. It introduces some new APIs which allow libata to be used without allocating a virtual scsi host. In the context of SAS, a struct ata_port is not a physical port, but rather becomes a virtual construct.

Since my last post, I have removed the dependence on the host_set struct. The following two patches depend on the qc_transport patch:

http://marc.theaimsgroup.com/?l=linux-ide&m=112845939215286&w=2

The API is the same as the last time I posted it to linux-ide, but here is the description again:

New APIs:

ata_sas_port_alloc - Allocate an ata_port
ata_sas_port_init - Initialize an ata_port (probe device, etc) ata_sas_port_destroy - Free an ata_port allocated by ata_sas_port_alloc ata_sas_slave_configure - configure scsi device ata_sas_queuecmd - queue a scsi command, similar to ata_scsi_queuecomand

These new APIs can be used either directly by a SAS LLDD or could be used by the SAS transport class.

Possible usage for a SAS LLDD would be:

scsi_scan_host
slave_alloc
ata_sas_port_alloc
ata_sas_port_init
slave_configure
ata_sas_slave_configure

Commands received by the LLDD for SATA devices would call ata_sas_queuecmd.

Device teardown would occur with:

slave_destroy
ata_sas_port_destroy

Signature · 3 lines
Brian King
eServer Storage I/O
IBM Linux Technology Center