From: Stefan Richter <stefanr@s5r6.in-berlin.de>
To: Rob Landley <rob@landley.net>
Cc: dougg@torque.net, James Bottomley <James.Bottomley@steeleye.com>,
linux-scsi@vger.kernel.org
Subject: Re: Some quick scsi documentation questions:
Date: Thu, 02 Aug 2007 23:39:55 +0200 [thread overview]
Message-ID: <46B24F2B.2060905@s5r6.in-berlin.de> (raw)
In-Reply-To: <46B2256A.3070902@torque.net>
> Rob Landley wrote:
>> So if you don't attach an sg to every sd, then either there are holes, or they
>> don't line up, in which case how do you tell which sg goes with a given sd?
Sysfs has pointers from a SCSI logical unit device to the corresponding
sd device and sg device...
$ ll /sys/bus/scsi/devices/1\:0\:0\:0/[bg]*
lrwxrwxrwx 1 root root 0 Aug 2 23:23
/sys/bus/scsi/devices/1:0:0:0/block:sdb -> ../../../../../../block/sdb
lrwxrwxrwx 1 root root 0 Aug 2 23:23
/sys/bus/scsi/devices/1:0:0:0/generic ->
../../../../../../class/scsi_generic/sg1
...as well as from the sd and sg devices to the corresponding SCSI
logical unit device:
$ ll /sys/block/sdb/device
lrwxrwxrwx 1 root root 0 Aug 2 23:27 /sys/block/sdb/device ->
../../devices/pci0000:00/0000:00:1f.2/host1/target1:0:0/1:0:0:0
$ ll /sys/class/scsi_generic/sg1/device
lrwxrwxrwx 1 root root 0 Aug 2 23:24 /sys/class/scsi_generic/sg1/device
-> ../../../devices/pci0000:00/0000:00:1f.2/host1/target1:0:0/1:0:0:0
The place where these symlinks live might change in the future. See
linux-2.6.23*/Documentation/sysfs-rules.txt.
--
Stefan Richter
-=====-=-=== =--- ---=-
http://arcgraph.de/sr/
next prev parent reply other threads:[~2007-08-02 21:40 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200707252328.28981.rob@landley.net>
[not found] ` <1185455711.3501.46.camel@localhost.localdomain>
2007-07-27 21:29 ` Some quick scsi documentation questions: Rob Landley
2007-08-02 18:41 ` Douglas Gilbert
2007-08-02 21:19 ` Stefan Richter
2007-08-03 0:55 ` Rob Landley
2007-08-03 10:43 ` Stefan Richter
2007-08-03 21:11 ` Rob Landley
2007-08-04 0:08 ` Stefan Richter
2007-08-04 0:35 ` Stefan Richter
2007-08-05 16:50 ` Douglas Gilbert
2007-08-06 16:29 ` Rob Landley
2007-08-06 18:30 ` Stefan Richter
2007-08-02 21:39 ` Stefan Richter [this message]
2007-08-03 1:12 ` Rob Landley
2007-08-03 8:15 ` Stefan Richter
2007-08-03 19:07 ` Rob Landley
2007-08-03 19:37 ` Stefan Richter
2007-08-03 21:39 ` Rob Landley
2007-08-03 0:39 ` Rob Landley
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=46B24F2B.2060905@s5r6.in-berlin.de \
--to=stefanr@s5r6.in-berlin.de \
--cc=James.Bottomley@steeleye.com \
--cc=dougg@torque.net \
--cc=linux-scsi@vger.kernel.org \
--cc=rob@landley.net \
/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