From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kay Sievers Date: Thu, 22 Jan 2004 23:27:23 +0000 Subject: Re: how to determine physical bus of a device and find it there Message-Id: <20040122232723.GA2196@vrfy.org> List-Id: References: <20040120025230.GA26199@vrfy.org> In-Reply-To: <20040120025230.GA26199@vrfy.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Thu, Jan 22, 2004 at 02:58:35PM -0800, Greg KH wrote: > On Thu, Jan 22, 2004 at 02:40:46PM -0800, Greg KH wrote: > > > > So what udev needs to do is look at each device along that "stack" in > > order to get a match. If a user specifies a idProduct sysfs file that > > is on the usb device at > > /sys/devices/pci0000:00/0000:00:1d.0/usb1/1-1/1-1:1.0 we should be able > > to match that up with this scsi block device, if so asked. > > > > It would also "solve" the problem where someone wanted to specify the > > idProduct and idVendor for a usb printer, but udev couldn't find it. > > And here's a horrible abuse of gotos that adds this support to udev. Oh, I like goto's too. :) Cool, works for me. Maybe "try_parent:" sounds better than "no_good" :) I will port it to udevinfo and print the keys with its correspondig BUS, so it should be easy for the user to build a rule. Btw. another question, do you know why this ugly multiline info is here? Doesn't it violate the sysfs conventions? kay@pim:/sys$ cat ./devices/pci0000:00/0000:00:1d.0/usb1/1-1/1-1.3/1-1.3:1.0/host32/32:0:0:1/info Host scsi32: usb-storage Vendor: SMSC Product: USB 2 Flash Media Device Serial Number: 0305037000C2 Protocol: Transparent SCSI Transport: Bulk Quirks: thanks, Kay ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel