]> git.hungrycats.org Git - linux/commit
[PATCH] One-shot support for epoll
authorAndrew Morton <akpm@osdl.org>
Tue, 20 Jan 2004 11:11:23 +0000 (03:11 -0800)
committerLinus Torvalds <torvalds@home.osdl.org>
Tue, 20 Jan 2004 11:11:23 +0000 (03:11 -0800)
commitedd011045dadc70d9c389040f750896ee9f12630
treee6fa7e35b0424ffed1d6eb3280e862948cf30099
parentf76fe2f64a622d02e7755c423db0c3cd4ba62589
[PATCH] One-shot support for epoll

From: Davide Libenzi <davidel@xmailserver.org>

The attached patch implements the one-shot support for epoll.  Because of
the way epoll works (hooking f_op->poll()) the ET behavior is not really ET
because it might happen that, while data is still available to read (for
the EPOLLIN case), another chunk will become available triggering another
event.

While those conditions can be easily be handled in userspace, the absolute
triviality of the patch and the avoidance of user/kernel space switches and
f_op->poll() calls, make IMHO worth doing this inside epoll itself.
fs/eventpoll.c
include/linux/eventpoll.h