Re: Reliable way to find out if a given uevent is proceeded ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 30, 2008 at 9:26 AM, Xinwei Hu <hxinwei@xxxxxxxxx> wrote:
>  I'm looking for a reliable way to find out if a given seqnum of
> uevent is proceeded.
>
>  The best way I found was
>
>     . read /dev/.udev/uevent_seqnum, make sure the uevent is enqueued already
>     . look for /dev/.udev/queue/$seqnum

You are just comparing it against /sys/kernel/uevent_seqnum, or you
have the kernel tell you the seqnum? I'm just asking, because we are
planning to make the seqnum available with kobject_uevent() to
synchronize actions between the kernel and userspace tools, which want
to sync with specific events.

>        -> if exist, not finished yet
>        -> if not, finished or failed
>
>  However, this is not a reliable way due to the fact that udevd write
> seqnum before
> export state into .udev/queue.
>
>  Are there any other solution to this problem ?
>  Or can we swap the order of writing seqnum and export state, like
> the attached patch do ?

Sounds fine. Applied.

Thanks,
Kay
--
To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel]     [Linux DVB]     [Asterisk Internet PBX]     [DCCP]     [Netdev]     [X.org]     [Util Linux NG]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux