public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* delay before open() works
@ 2002-09-14 16:42 Brian Craft
  2002-09-15  5:25 ` Brad Hards
  0 siblings, 1 reply; 6+ messages in thread
From: Brian Craft @ 2002-09-14 16:42 UTC (permalink / raw)
  To: linux-kernel

Hi -- I notice in 2.4 kernels that there's a delay between completion of
"modprobe scanner" and when the device file can be successfully opened. I'm
working on code to power-up devices on-demand.

I've played some with making scripts to work around this, like

  heyu turn on scanner
  modprobe scanner
  sleep 15
  xsane

This is pretty gross, since I have to determine the "15" by playing with it,
and I'm sure it will fail some of the time unless I make it reeeeeally long. I
suspected this was some hardware issue -- USB latencies on device discovery, or
boot time for the scanner -- but a friend who isn't attempting to power-up his
devices says he sees the same behavior when just scripting "modprobe". So it
appears there's some fairly long delay in the kernel itself.

Anyone know off-hand what causes this delay, or if there's some way to get
the open() to block?

(btw, I'm not subscribed to the list).
b.c.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2002-09-15  6:48 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-09-14 16:42 delay before open() works Brian Craft
2002-09-15  5:25 ` Brad Hards
2002-09-15  6:10   ` Greg KH
2002-09-15  6:38     ` Brad Hards
2002-09-15  6:49       ` Greg KH
2002-09-15  6:20   ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox