Re: Suggested addition to epoll interface - epoll_post_notification()

From: Roland Dreier
Date: Tue Sep 15 2009 - 14:17:01 EST



> I have been playing with epoll lately and I would like to make a suggestion
> regarding the epoll interface.
> It would be nice to have a function to wake up a thread/process that is blocked
> on an epoll_wait() call and sent it some
> user defined data in the form of a struct epoll_event parameter ( something
> similar with PostQueuedCompletionStatus() from Windows ).

You might have a look at eventfd() which creates an fd that can be used
to signal from one thread to another (and which can be waited on with epoll).

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