All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kay Sievers <kay.sievers-tD+1rO4QERM@public.gmane.org>
To: Seewer Philippe <philippe.seewer-omB+W0Dpw2o@public.gmane.org>
Cc: initramfs <initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: udevadm settle timeout semantics
Date: Thu, 18 Jun 2009 14:16:25 +0200	[thread overview]
Message-ID: <1245327385.7315.3.camel@yio.site> (raw)
In-Reply-To: <4A3A218C.7020405-omB+W0Dpw2o@public.gmane.org>

On Thu, 2009-06-18 at 13:14 +0200, Seewer Philippe wrote:
> The manpage for udevadm (version 141) says about the timeout for settle 
> and --timeout:
> 
> [quote]
> udevadm settle [options]
>         Watches the udev event queue, and exits if all
>         current events are handled.
> 
> --timeout=seconds
>             Maximum number of seconds to wait for the event
>             queue to become empty. The default value is 180
>             seconds. A value of 0 will check if the queue
>             is empty and always return immediately.
> [/quote]
> 
> 
> Am I reading this correctly if I assume that udevadm has to wait for an 
> event to be "handled" regardless of the timeout value?
> 
> Example: dhclient has a default of 60 seconds to try to get an ip 
> address until it fails. udevadm settle waits for the whole 60 seconds to 
> pass regardless of the timeout parameter.
> 
> Is this behaviour as intended?

The timeout is the maximum to wait:

  $ echo 'RUN+="/bin/sleep 300"' > /etc/udev/rules.d/00.rules
  $ echo add > /sys/class/mem/zero/uevent

  $ time udevadm settle --timeout=3
  udevadm settle - timeout of 3 seconds reached, the event queue contains:
  /sys/devices/virtual/mem/zero (1796)

Not sure, udev 141 maybe had a bug here.

Thanks,
Kay

--
To unsubscribe from this list: send the line "unsubscribe initramfs" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2009-06-18 12:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-18 11:14 udevadm settle timeout semantics Seewer Philippe
     [not found] ` <4A3A218C.7020405-omB+W0Dpw2o@public.gmane.org>
2009-06-18 12:16   ` Kay Sievers [this message]
     [not found]     ` <1245327385.7315.3.camel-2/CBIq5w30c@public.gmane.org>
2009-06-18 12:55       ` Seewer Philippe
     [not found]         ` <4A3A393C.6000405-omB+W0Dpw2o@public.gmane.org>
2009-06-19  2:51           ` David Dillow

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=1245327385.7315.3.camel@yio.site \
    --to=kay.sievers-td+1ro4qerm@public.gmane.org \
    --cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=philippe.seewer-omB+W0Dpw2o@public.gmane.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.