Re: Simple Kernel-User Event Interface (Was: RE: [ANNOUNCE] udev 0.1 release)

Greg KH (greg@kroah.com)
Fri, 11 Apr 2003 22:54:17 -0700


On Fri, Apr 11, 2003 at 09:16:02PM -0700, Perez-Gonzalez, Inaky wrote:
>
> Okay, so what about this:
>
> I started playing with a simple event interface, that would allow:
>
> - queuing events and recalling-queued events
> - not consume (almost) memory when two bazillion events are queued
> - be accessible by different processes at the same time on
> different fds

Have you looked at relayfs? I think it might do much the same thing as
this, but through a fs interface, instead of a char device node.

> Now, each fd keeps a pointer to the queue list and only when the
> event has been read by all the open fds, it is then disposed.

I don't think you can just count the number of open fds, like your patch
does to get a count of who all read this message (fds can close and
others can open, so newer fds might not have read the message before it
is removed.)

Looks like a good start, but I'm not moving the hotplug interface over
to it :)

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/