All of lore.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi@qumranet.com>
To: Laurent Vivier <Laurent.Vivier@bull.net>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] Merge NBD client/server int qemu-nbd
Date: Sat, 14 Jun 2008 12:06:58 -0700	[thread overview]
Message-ID: <485416D2.9050900@qumranet.com> (raw)
In-Reply-To: <1213470224.3843.11.camel@frecb07144>

Laurent Vivier wrote:
> 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).
>   

It is udev that creates the devices, based on events it receives from 
the kernel.  Calling udevsettle after the kernel instructs udev to 
create the device files will wait until they are actually created.

-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.

  reply	other threads:[~2008-06-14 19:07 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-13 15:15 [Qemu-devel] [PATCH] Merge NBD client/server int qemu-nbd Laurent Vivier
2008-06-13 17:49 ` Anthony Liguori
2008-06-13 18:09   ` Avi Kivity
2008-06-13 18:39   ` Laurent Vivier
2008-06-14 15:12     ` Anthony Liguori
2008-06-14 18:47       ` Laurent Vivier
2008-06-14 17:18     ` Avi Kivity
2008-06-14 19:03       ` Laurent Vivier
2008-06-14 19:06         ` Avi Kivity [this message]
2008-06-14 19:21           ` Laurent Vivier
2008-06-14 19:35             ` Avi Kivity
2008-06-14 19:54               ` Laurent Vivier
2008-06-15 14:25                 ` Anthony Liguori
2008-06-15 15:56                   ` Laurent Vivier
2008-06-15 16:00                     ` Avi Kivity
2008-06-15 17:39                       ` Laurent Vivier
2008-06-19  8:58                         ` [Qemu-devel] [PATCH][v2] " Laurent Vivier
2008-06-19  9:18                           ` Laurent Vivier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=485416D2.9050900@qumranet.com \
    --to=avi@qumranet.com \
    --cc=Laurent.Vivier@bull.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.