Re: [RFC] SAS domain layout for Linux sysfs

From: Christoph Hellwig
Date: Sun Apr 24 2005 - 06:21:24 EST

On Wed, Apr 13, 2005 at 11:22:23AM -0400, Luben Tuikov wrote:
> SAS domain layout for Linux sysfs
> =================================
> 0. Introduction
> The use of SAS address and WWN are used interchangeably.
> There are two domains which we want to represent in sysfs, in
> order to eliminate redundancies.
> | /-------------------\
> +-------+ | / SAS_ADDR0 \
> |ha0 [] =---|---( )
> +---||||+ | \ /
> | | SAS_ADDR2 |
> +-------+ | / \
> |ha1 [] =---|---( SAS_ADDR1 )
> +---||||+ | \ /
> | \___________________/
> |
> Host domain | SAS Domain
> Figure 1. Domains represented by sysfs
> The host domain (/sys/class/sas_ha/ha0/, etc) shows the SAS
> domain as seen by the Host Adapter. The sysfs SAS domain
> (/sys/bus/sas/ ), shows the SAS domain as it exists
> irrespectively of which HA (Host Adapter) you use to connect
> to it (to a device).

This is contrary to any sysfs topology I know about, especially any
existing transport class (SPI, FC, iSCSI). We only ever care about
what's seen from a HA, e.g. if you have muliple SPI cards that are
on a single parallel bus you'll have the same bus represented twice,
similarly if you have two fibre channel HBAs connected to the same
SAN you'll have the SAN topology duplicated in both sub-topologies.
This matches the internal data structure of the scsi subsystem and
the transport class, e.g. we have a scsi_device object for every lun
that's seen from a hba, linked to the HBAs Scsi_Host object and not
one shared by multiple HBAs. Dito for fibre channel remote ports.

One note to this proposal: it probably doesn't make a lot of sense to
try to flesh out the sysfs topology before doing the kernel internal
object model as the former pretty much follows the latter.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at