summaryrefslogtreecommitdiff
path: root/include/linux/eventpoll.h
diff options
context:
space:
mode:
authorPaton J. Lewis <palewis@adobe.com>2012-10-05 04:13:39 +0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-10-05 22:05:00 +0400
commit03a7beb55b9fad363f0dd33e72ccf2d3e1c2a406 (patch)
treee89cb2a2db5645600f28699ebf3b4a98195a3fb3 /include/linux/eventpoll.h
parenta0a0a7a94c765f7219b57fa3b79389901bb0bc99 (diff)
downloadlinux-03a7beb55b9fad363f0dd33e72ccf2d3e1c2a406.tar.xz
epoll: support for disabling items, and a self-test app
Enhanced epoll_ctl to support EPOLL_CTL_DISABLE, which disables an epoll item. If epoll_ctl doesn't return -EBUSY in this case, it is then safe to delete the epoll item in a multi-threaded environment. Also added a new test_epoll self- test app to both demonstrate the need for this feature and test it. Signed-off-by: Paton J. Lewis <palewis@adobe.com> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Jason Baron <jbaron@redhat.com> Cc: Paul Holland <pholland@adobe.com> Cc: Davide Libenzi <davidel@xmailserver.org> Cc: Michael Kerrisk <mtk.manpages@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/eventpoll.h')
-rw-r--r--include/linux/eventpoll.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/eventpoll.h b/include/linux/eventpoll.h
index f4bb378ccf6a..41085d0f3955 100644
--- a/include/linux/eventpoll.h
+++ b/include/linux/eventpoll.h
@@ -25,6 +25,7 @@
#define EPOLL_CTL_ADD 1
#define EPOLL_CTL_DEL 2
#define EPOLL_CTL_MOD 3
+#define EPOLL_CTL_DISABLE 4
/*
* Request the handling of system wakeup events so as to prevent system suspends