From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Mon, 03 Jun 2002 23:16:34 +0000 Subject: Re: Which node has the device been bound to? Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Tue, Jun 04, 2002 at 01:05:09AM +0200, Oliver Neukum wrote: > > > > I can't come up with anything better than a set of ioctls that return > > > the contents of the individual files. And I know that this is ugly. > > > I don't claim that this is a good solution, just that it's the only > > > solution I have and that there's a race otherwise. > > > You simply cannot use names, thus parsing files for the name of the > > > node won't work. > > > > Or we could just drop the whole idea of using ioctl() and live with the > > "instability" of parsing a filesystem :) > > There is no such thing is an acceptable race condition. Then use the device tree in driverfs as a "hint" as to where you might find your device. Then rely on other things (fs labels, usb serial numbers, ethernet mac addresses, etc.) to verify if the device you are talking to really is the one you think it is. thanks, greg k-h _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ 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