qemu-devel@nongnu.org
[Top] [All Lists]

Re: [Qemu-devel] [PATCH] Merge NBD client/server int qemu-nbd

Subject: Re: [Qemu-devel] [PATCH] Merge NBD client/server int qemu-nbd
From: Laurent Vivier
Date: Sat, 14 Jun 2008 21:03:43 +0200
Le samedi 14 juin 2008 Ã 20:18 +0300, Avi Kivity a Ãcrit :
> Laurent Vivier wrote:
> > int timeout = 5;
> > while ((fd = open(device, O_RDWR)) == -1 && timeout--)
> >     sleep(1);
> >
> > Any suggestion ???
> >
> >   
> 
> /sbin/udevsettle

Why do you think udev is involved at this moment ?

/dev/nbd0 is created when the module is loaded (thus before) and the
partitions when the partition table is read (from within the open).

Regards,
Laurent
-- 
------------- Laurent.Vivier@xxxxxxxx ---------------
"The best way to predict the future is to invent it."
- Alan Kay



<Prev in Thread] Current Thread [Next in Thread>