diff --git a/man2/select.2 b/man2/select.2 index b0a24d8d2..7c3346a34 100644 --- a/man2/select.2 +++ b/man2/select.2 @@ -469,6 +469,30 @@ when .B _GNU_SOURCE is defined. Since glibc 2.2.2, the requirements are as shown in the SYNOPSIS. +.\" +.SS Correspondence between select() and poll() notifications +Within the Linux kernel source, +.\" fs/select.c +we find the following definitions which show the correspondence +between the readable, writable, and exceptional condition notifications of +.BR select () +and the event notifications provided by +.BR poll (2) +(and +.BR epoll (7)): + +.nf +.in +4n +#define POLLIN_SET (POLLRDNORM | POLLRDBAND | POLLIN | POLLHUP | + POLLERR) + /* Ready for reading */ +#define POLLOUT_SET (POLLWRBAND | POLLWRNORM | POLLOUT | POLLERR) + /* Ready for writing */ +#define POLLEX_SET (POLLPRI) + /* Exceptional condition */ +.in +.fi +.\" .SS Multithreaded applications If a file descriptor being monitored by .BR select ()