From: Douglas Gilbert <dougg@torque.net>
To: Andries.Brouwer@cwi.nl
Cc: garloff@suse.de, linux-kernel@vger.kernel.org,
linux-scsi@vger.kernel.org, sancho@dauskardt.de,
linux-usb-devel@lists.sourceforge.net,
linux1394-devel@lists.sourceforge.net
Subject: Re: /proc/scsi/map
Date: Sat, 15 Jun 2002 18:27:23 -0400 [thread overview]
Message-ID: <3D0BBF4B.42E355A6@torque.net> (raw)
In-Reply-To: UTC200206152154.g5FLsCI23053.aeb@smtp.cwi.nl
Andries.Brouwer@cwi.nl wrote:
>
> >Life would be easier if the scsi subsystem would just report which SCSI
> >device (uniquely identified by the controller,bus,target,unit tuple) belongs
> >to which high-level device. The information is available in the kernel.
> >
> >Attached patch does this:
> >garloff@pckurt:/raid5/Kernel/src $ cat /proc/scsi/map
> ># C,B,T,U Type onl sg_nm sg_dev nm dev(hex)
> >0,0,00,00 0x05 1 sg0 c:15:00 sr0 b:0b:00
> [...]
>
> Great, this was really missing badly.
>
> But how about adding another column: GUID.
> Most usb-storage and (all?) FireWire devices have such a unique identitiy.
> In contrast to native SCSI devices, these emulated SCSI devices on
> hot-plugging busses will change their LUNs/IDs. Therefor the GUID is
> really a must to be able to create stable names (laptop suspend, etc.).
>
> Both usb-storage and iee1394-sbp2 know the GUID. It only needs to be
> communicated..
>
> The usb-storage GUID is just one random item of information.
> One might wish for much more.
>
> And: this information is already somewhere:
>
> % cat /proc/scsi/sg/host_strs
> SCSI host adapter emulation for IDE ATAPI devices
> Iomega VPI2 (imm) interface
> SCSI emulation for USB Mass Storage devices
> SCSI emulation for USB Mass Storage devices
> %
>
> This tells me that host 0 will be in ide-scsi, host 1 in imm,
> host 2 in usb-storage-0, host 3 in usb-storage-1.
> And
>
> % cat /proc/scsi/ide-scsi/0
> SCSI host adapter emulation for IDE ATAPI devices
> % cat /proc/scsi/imm/1
> Version : 2.05 (for Linux 2.4.0)
> Parport : parport0
> Mode : SPP
> % cat /proc/scsi/usb-storage-0/2
> Host scsi2: usb-storage
> Vendor: DataFab Systems Inc.
> Product: USB CF+SM
> Serial Number: 5DC69477C6
> Protocol: Transparent SCSI
> Transport: Datafab Bulk-Only
> GUID: 07c4a1090000005dc69477c6
> Attached: Yes
> % cat /proc/scsi/usb-storage-1/3
> Host scsi3: usb-storage
> Vendor: SCM Microsystems Inc.
> Product: eUSB SmartMedia / CompactFlash
> Serial Number: None
> Protocol: Transparent SCSI
> Transport: Control/Bulk-EUSB/SDDR09
> GUID: 04e600050000000000000000
> Attached: Yes
> %
>
> A small utility that looks around in /proc is able to
> find the GUID. Of course it would be better when fewer
> heuristics were required.
>
> Finally, the GUIDs you see here do not determine the LUN.
> So, there is no well-defined line in /proc/scsi/map
> where they would belong.
In lk 2.5 we are hoping that driverfs will give us an
"information bridge" between scsi pseudo devices
and other driver subsystems such as ide, usb and iee1394.
Mike Sullivan's persistent naming patch (that I mentioned
in my previous post on this thread) adds driverfs capability
into the scsi subsystem. Driverfs capability is already
in the ide and usb subsystems.
procfs, driverfs and devfs ...
Doug Gilbert
next parent reply other threads:[~2002-06-15 22:27 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <UTC200206152154.g5FLsCI23053.aeb@smtp.cwi.nl>
2002-06-15 22:27 ` Douglas Gilbert [this message]
2002-06-15 22:40 ` /proc/scsi/map Sancho Dauskardt
2002-06-16 20:36 ` /proc/scsi/map Kurt Garloff
2002-06-15 22:28 ` /proc/scsi/map Sancho Dauskardt
2002-06-16 17:05 ` [linux-usb-devel] /proc/scsi/map David Brownell
2002-06-18 15:40 /proc/scsi/map Bryan Henderson
2002-06-18 16:09 ` /proc/scsi/map Doug Ledford
-- strict thread matches above, loose matches on Subject: below --
2002-06-17 22:06 /proc/scsi/map Bryan Henderson
2002-06-17 15:57 /proc/scsi/map Bryan Henderson
2002-06-17 20:28 ` /proc/scsi/map Kurt Garloff
2002-06-17 12:55 /proc/scsi/map Heinz, Michael
[not found] <UTC200206151604.g5FG4JQ26968.aeb@smtp.cwi.nl>
2002-06-16 21:04 ` /proc/scsi/map Kurt Garloff
2002-06-16 8:24 /proc/scsi/map Andries.Brouwer
2002-06-15 23:00 /proc/scsi/map Andries.Brouwer
2002-06-15 21:54 /proc/scsi/map Andries.Brouwer
2002-06-15 21:08 /proc/scsi/map Douglas Gilbert
[not found] <garloff@suse.de>
2002-06-15 13:36 ` /proc/scsi/map Kurt Garloff
2002-06-15 14:08 ` /proc/scsi/map John Summerfield
2002-06-17 11:33 ` /proc/scsi/map Kurt Garloff
2002-06-15 15:52 ` /proc/scsi/map Richard Gooch
2002-06-16 19:41 ` /proc/scsi/map Kurt Garloff
2002-06-15 19:49 ` /proc/scsi/map Sancho Dauskardt
2002-06-16 19:24 ` /proc/scsi/map Albert D. Cahalan
2002-06-16 21:22 ` /proc/scsi/map Kurt Garloff
2002-06-17 20:35 ` /proc/scsi/map Patrick Mansfield
2002-06-17 20:57 ` /proc/scsi/map Kurt Garloff
2002-06-17 21:47 ` /proc/scsi/map Patrick Mansfield
2002-06-17 22:08 ` /proc/scsi/map Doug Ledford
2002-06-17 23:06 ` /proc/scsi/map Kurt Garloff
[not found] ` <20020617230648.GA3448@gum01m.etpnet.phys.tue.nl>
2002-06-18 2:40 ` /proc/scsi/map Doug Ledford
2002-06-18 4:32 ` /proc/scsi/map Douglas Gilbert
2002-06-18 5:12 ` /proc/scsi/map Doug Ledford
2002-06-18 9:03 ` /proc/scsi/map Kurt Garloff
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=3D0BBF4B.42E355A6@torque.net \
--to=dougg@torque.net \
--cc=Andries.Brouwer@cwi.nl \
--cc=garloff@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=linux-usb-devel@lists.sourceforge.net \
--cc=linux1394-devel@lists.sourceforge.net \
--cc=sancho@dauskardt.de \
/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