[sane-devel] scanimage timeouts
Wed, 22 Jan 2003 18:20:53 +0100
On Wed, Jan 22, 2003 at 04:24:09PM +0300, Sergey Vlasov wrote:
> On Tue, Jan 21, 2003 at 23:48:38 +0100, Henning Meier-Geinitz wrote:
> > I quick test shows that opening non-existing devices with devfs is
> > just extremely slow. The same goes for stat() instead of open().
> > 1000 stats take 11 seconds if the file does not exist and 0.01
> > seconds if it exists :-(((
> devfs has a special handling for file lookup - it catches attempts to open
> non-existent files and passes the requests to devfsd, which then can load
> the required module.
> Because of this requirement, opening a non-existent device with devfs
> always will be slow.
Thanks for the explanation. sanei_usb now reads the directory and only
opens files that are listed there.