X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=original%2Fman2%2Fpoll.2;h=e0ed1f93712f7d1b3d812a6d4e261ddc3dea2708;hb=361fd72f831aabd8a0aa6fe7bc4ef66ef4f89a1b;hp=ba6a523251ded3923bc14af781c5d05f04b85ffe;hpb=e9e6c106d11bd9cca5f4a6585364b93f5ae3007a;p=linuxjm%2FLDP_man-pages.git diff --git a/original/man2/poll.2 b/original/man2/poll.2 index ba6a5232..e0ed1f93 100644 --- a/original/man2/poll.2 +++ b/original/man2/poll.2 @@ -28,7 +28,7 @@ .\" 2006-07-01, mtk, Added POLLRDHUP + various other wording and .\" formatting changes. .\" -.TH POLL 2 2012-08-17 "Linux" "Linux Programmer's Manual" +.TH POLL 2 2014-01-31 "Linux" "Linux Programmer's Manual" .SH NAME poll, ppoll \- wait for some event on a file descriptor .SH SYNOPSIS @@ -89,12 +89,15 @@ The field is an input parameter, a bit mask specifying the events the application is interested in for the file descriptor .IR fd . -If this field is specified as zero, -then all events are ignored for -.IR fd -and +This field may be specified as zero, +in which case the only events that can be returned in .I revents -returns zero. +are +.BR POLLHUP , +.BR POLLERR , +and +.B POLLNVAL +(see below). The field .I revents @@ -122,12 +125,22 @@ blocks until one of the events occurs. The .I timeout -argument specifies the minimum number of milliseconds that +argument specifies the number of milliseconds that .BR poll () -will block. -(This interval will be rounded up to the system clock granularity, +should block waiting for a file descriptor to become ready. +The call will block until either: +.IP * 3 +a file descriptor becomes ready; +.IP * +the call is interrupted by a signal handler; or +.IP * +the timeout expires. +.PP +Note that the +.I timeout +interval will be rounded up to the system clock granularity, and kernel scheduling delays mean that the blocking interval -may overrun by a small amount.) +may overrun by a small amount. Specifying a negative value in .I timeout means an infinite timeout. @@ -364,6 +377,15 @@ See the discussion of spurious readiness notifications under the BUGS section of .BR select (2). .SH SEE ALSO +.BR restart_syscall (2), .BR select (2), .BR select_tut (2), .BR time (7) +.SH COLOPHON +This page is part of release 3.65 of the Linux +.I man-pages +project. +A description of the project, +and information about reporting bugs, +can be found at +\%http://www.kernel.org/doc/man\-pages/.