On Thu, Dec 18, 2003 at 09:53:03AM +0100, Oliver Neukum wrote: > Am Mittwoch, 17. Dezember 2003 18:47 schrieb Greg KH: > > On Wed, Dec 17, 2003 at 06:28:13PM +0100, Bertrik Sikken wrote: > > > >Exactly. Try putting a sleep before reading the file, or loop on the > > > >file for a bit before reading it. > > > > > > I can confirm that the sleep works (added a sleep 1 at the start > > > of the script). Does this suggest an issue in the kernel? > > > > No, it's not a problem with the kernel, it's just something that you > > need to be aware of in your hotplug scripts. > > Technically, it is a race condition. > You need to make sure that user space loses the race. Shouldn't this actually be two separate hotplug events? One when the unit is physically attached, to load the usb-storage driver. The second when the SCSI layer has initalized the device, to run the scsi.agent? Matt -- Matthew Dharm Home: mdharm-usb@one-eyed-alien.net Maintainer, Linux USB Mass Storage Driver A female who groks UNIX? My universe is collapsing. -- Mike User Friendly, 10/11/1998