]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man2/timerfd_create.2
des_crypt.3: Minor wording fix in VERSIONS
[thirdparty/man-pages.git] / man2 / timerfd_create.2
CommitLineData
45b81c9c
MK
1.\" Copyright (C) 2008 Michael Kerrisk <mtk.manpages@gmail.com>
2.\"
f0008367 3.\" %%%LICENSE_START(GPLv2+_SW_3_PARA)
45b81c9c
MK
4.\" This program is free software; you can redistribute it and/or modify
5.\" it under the terms of the GNU General Public License as published by
6.\" the Free Software Foundation; either version 2 of the License, or
7.\" (at your option) any later version.
8.\"
9.\" This program is distributed in the hope that it will be useful,
10.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
11.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12.\" GNU General Public License for more details.
13.\"
68fa4398
MK
14.\" You should have received a copy of the GNU General Public
15.\" License along with this manual; if not, see
16.\" <http://www.gnu.org/licenses/>.
8ff7380d 17.\" %%%LICENSE_END
45b81c9c 18.\"
e8426ca2 19.TH TIMERFD_CREATE 2 2020-04-11 Linux "Linux Programmer's Manual"
45b81c9c
MK
20.SH NAME
21timerfd_create, timerfd_settime, timerfd_gettime \-
22timers that notify via file descriptors
23.SH SYNOPSIS
45b81c9c
MK
24.nf
25.B #include <sys/timerfd.h>
68e4db0a 26.PP
45b81c9c 27.BI "int timerfd_create(int " clockid ", int " flags );
68e4db0a 28.PP
45b81c9c
MK
29.BI "int timerfd_settime(int " fd ", int " flags ,
30.BI " const struct itimerspec *" new_value ,
5c902597 31.BI " struct itimerspec *" old_value );
68e4db0a 32.PP
45b81c9c
MK
33.BI "int timerfd_gettime(int " fd ", struct itimerspec *" curr_value );
34.fi
35.SH DESCRIPTION
36These system calls create and operate on a timer
37that delivers timer expiration notifications via a file descriptor.
38They provide an alternative to the use of
39.BR setitimer (2)
40or
804f03e6 41.BR timer_create (2),
45b81c9c
MK
42with the advantage that the file descriptor may be monitored by
43.BR select (2),
44.BR poll (2),
45and
46.BR epoll (7).
efeece04 47.PP
45b81c9c 48The use of these three system calls is analogous to the use of
804f03e6
MK
49.BR timer_create (2),
50.BR timer_settime (2),
45b81c9c 51and
804f03e6 52.BR timer_gettime (2).
45b81c9c 53(There is no analog of
804f03e6 54.BR timer_getoverrun (2),
45b81c9c
MK
55since that functionality is provided by
56.BR read (2),
57as described below.)
58.\"
59.SS timerfd_create()
60.BR timerfd_create ()
61creates a new timer object,
62and returns a file descriptor that refers to that timer.
63The
64.I clockid
65argument specifies the clock that is used to mark the progress
205b1bce 66of the timer, and must be one of the following:
4b76fffb 67.TP
45b81c9c 68.B CLOCK_REALTIME
4b76fffb
MK
69A settable system-wide real-time clock.
70.TP
45b81c9c 71.B CLOCK_MONOTONIC
4b76fffb
MK
72A nonsettable monotonically increasing clock that measures time
73from some unspecified point in the past that does not change
74after system startup.
4c747119
MK
75.TP
76.BR CLOCK_BOOTTIME " (Since Linux 3.15)"
77.\" commit 4a2378a943f09907fb1ae35c15de917f60289c14
78Like
79.BR CLOCK_MONOTONIC ,
80this is a monotonically increasing clock.
81However, whereas the
82.BR CLOCK_MONOTONIC
83clock does not measure the time while a system is suspended, the
84.BR CLOCK_BOOTTIME
85clock does include the time during which the system is suspended.
86This is useful for applications that need to be suspend-aware.
87.BR CLOCK_REALTIME
88is not suitable for such applications, since that clock is affected
89by discontinuous changes to the system clock.
90.TP
91.BR CLOCK_REALTIME_ALARM " (since Linux 3.11)"
92.\" commit 11ffa9d6065f344a9bd769a2452f26f2f671e5f8
93This clock is like
94.BR CLOCK_REALTIME ,
95but will wake the system if it is suspended.
96The caller must have the
97.B CAP_WAKE_ALARM
98capability in order to set a timer against this clock.
99.TP
100.BR CLOCK_BOOTTIME_ALARM " (since Linux 3.11)"
101.\" commit 11ffa9d6065f344a9bd769a2452f26f2f671e5f8
102This clock is like
103.BR CLOCK_BOOTTIME ,
104but will wake the system if it is suspended.
105The caller must have the
106.B CAP_WAKE_ALARM
107capability in order to set a timer against this clock.
4b76fffb 108.PP
ff5de6ec
MK
109See
110.BR clock_getres (2)
111for some further details on the above clocks.
112.PP
45b81c9c 113The current value of each of these clocks can be retrieved using
0eb44391 114.BR clock_gettime (2).
efeece04 115.PP
3df1b973
MK
116Starting with Linux 2.6.27, the following values may be bitwise ORed in
117.IR flags
118to change the behavior of
119.BR timerfd_create ():
120.TP 14
121.B TFD_NONBLOCK
122Set the
123.BR O_NONBLOCK
7f11e32c
MK
124file status flag on the open file description (see
125.BR open (2))
126referred to by the new file descriptor.
3df1b973 127Using this flag saves extra calls to
ef7db4f5 128.BR fcntl (2)
3df1b973
MK
129to achieve the same result.
130.TP
131.B TFD_CLOEXEC
132Set the close-on-exec
133.RB ( FD_CLOEXEC )
134flag on the new file descriptor.
c5571b61 135See the description of the
3df1b973
MK
136.B O_CLOEXEC
137flag in
138.BR open (2)
139for reasons why this may be useful.
140.PP
141In Linux versions up to and including 2.6.26,
45b81c9c 142.I flags
3df1b973 143must be specified as zero.
45b81c9c
MK
144.SS timerfd_settime()
145.BR timerfd_settime ()
146arms (starts) or disarms (stops)
147the timer referred to by the file descriptor
148.IR fd .
efeece04 149.PP
45b81c9c
MK
150The
151.I new_value
152argument specifies the initial expiration and interval for the timer.
153The
251ebc1e 154.I itimerspec
45b81c9c
MK
155structure used for this argument contains two fields,
156each of which is in turn a structure of type
157.IR timespec :
e646a1ba 158.PP
45b81c9c 159.in +4n
e646a1ba 160.EX
45b81c9c
MK
161struct timespec {
162 time_t tv_sec; /* Seconds */
163 long tv_nsec; /* Nanoseconds */
164};
165
166struct itimerspec {
167 struct timespec it_interval; /* Interval for periodic timer */
168 struct timespec it_value; /* Initial expiration */
169};
b8302363 170.EE
45b81c9c
MK
171.in
172.PP
173.I new_value.it_value
174specifies the initial expiration of the timer,
175in seconds and nanoseconds.
176Setting either field of
177.I new_value.it_value
c7094399 178to a nonzero value arms the timer.
45b81c9c
MK
179Setting both fields of
180.I new_value.it_value
181to zero disarms the timer.
efeece04 182.PP
45b81c9c
MK
183Setting one or both fields of
184.I new_value.it_interval
c7094399 185to nonzero values specifies the period, in seconds and nanoseconds,
45b81c9c
MK
186for repeated timer expirations after the initial expiration.
187If both fields of
188.I new_value.it_interval
189are zero, the timer expires just once, at the time specified by
190.IR new_value.it_value .
efeece04 191.PP
51062576
MK
192By default,
193the initial expiration time specified in
194.I new_value
195is interpreted relative to the current time
196on the timer's clock at the time of the call (i.e.,
197.I new_value.it_value
198specifies a time relative to the current value of the clock specified by
199.IR clockid ).
200An absolute timeout can be selected via the
201.I flags
202argument.
efeece04 203.PP
45b81c9c
MK
204The
205.I flags
51062576
MK
206argument is a bit mask that can include the following values:
207.TP
208.B TFD_TIMER_ABSTIME
209Interpret
210.I new_value.it_value
211as an absolute value on the timer's clock.
212The timer will expire when the value of the timer's
45b81c9c 213clock reaches the value specified in
51062576 214.IR new_value.it_value .
e9477548
MK
215.TP
216.BR TFD_TIMER_CANCEL_ON_SET
217If this flag is specified along with
218.B TFD_TIMER_ABSTIME
219and the clock for this timer is
220.BR CLOCK_REALTIME
221or
222.BR CLOCK_REALTIME_ALARM ,
223then mark this timer as cancelable if the real-time clock
224undergoes a discontinuous change
225.RB ( settimeofday (2),
226.BR clock_settime (2),
227or similar).
228When such changes occur, a current or future
229.BR read (2)
230from the file descriptor will fail with the error
231.BR ECANCELED .
51062576 232.PP
009cdc22 233If the
5c902597 234.I old_value
009cdc22
MK
235argument is not NULL, then the
236.I itimerspec
237structure that it points to is used to return the setting of the timer
238that was current at the time of the call;
239see the description of
45b81c9c
MK
240.BR timerfd_gettime ()
241following.
242.\"
243.SS timerfd_gettime()
244.BR timerfd_gettime ()
245returns, in
246.IR curr_value ,
247an
248.IR itimerspec
dc55661b 249structure that contains the current setting of the timer
45b81c9c
MK
250referred to by the file descriptor
251.IR fd .
efeece04 252.PP
45b81c9c
MK
253The
254.I it_value
255field returns the amount of time
256until the timer will next expire.
257If both fields of this structure are zero,
258then the timer is currently disarmed.
259This field always contains a relative value, regardless of whether the
260.BR TFD_TIMER_ABSTIME
261flag was specified when setting the timer.
efeece04 262.PP
45b81c9c
MK
263The
264.I it_interval
265field returns the interval of the timer.
266If both fields of this structure are zero,
267then the timer is set to expire just once, at the time specified by
268.IR curr_value.it_value .
269.SS Operating on a timer file descriptor
270The file descriptor returned by
271.BR timerfd_create ()
066dcd09 272supports the following additional operations:
45b81c9c
MK
273.TP
274.BR read (2)
275If the timer has already expired one or more times since
276its settings were last modified using
277.BR timerfd_settime (),
278or since the last successful
279.BR read (2),
280then the buffer given to
281.BR read (2)
282returns an unsigned 8-byte integer
283.RI ( uint64_t )
284containing the number of expirations that have occurred.
88879aeb
MK
285(The returned value is in host byte order\(emthat is,
286the native byte order for integers on the host machine.)
45b81c9c
MK
287.IP
288If no timer expirations have occurred at the time of the
289.BR read (2),
290then the call either blocks until the next timer expiration,
291or fails with the error
292.B EAGAIN
ff40dbb3 293if the file descriptor has been made nonblocking
45b81c9c
MK
294(via the use of the
295.BR fcntl (2)
296.B F_SETFL
297operation to set the
298.B O_NONBLOCK
299flag).
300.IP
301A
302.BR read (2)
26cd31fd 303fails with the error
45b81c9c
MK
304.B EINVAL
305if the size of the supplied buffer is less than 8 bytes.
efeece04 306.IP
e9477548
MK
307If the associated clock is either
308.BR CLOCK_REALTIME
309or
310.BR CLOCK_REALTIME_ALARM ,
311the timer is absolute
312.RB ( TFD_TIMER_ABSTIME ),
313and the flag
314.BR TFD_TIMER_CANCEL_ON_SET
315was specified when calling
316.BR timerfd_settime (),
317then
318.BR read (2)
26cd31fd 319fails with the error
e9477548
MK
320.BR ECANCELED
321if the real-time clock undergoes a discontinuous change.
322(This allows the reading application to discover
323such discontinuous changes to the clock.)
1ae24555
MK
324.IP
325If the associated clock is either
326.BR CLOCK_REALTIME
327or
328.BR CLOCK_REALTIME_ALARM ,
329the timer is absolute
330.RB ( TFD_TIMER_ABSTIME ),
331and the flag
332.BR TFD_TIMER_CANCEL_ON_SET
333was
334.I not
335specified when calling
336.BR timerfd_settime (),
337then a discontinuous negative change to the clock (e.g.,
338.BR clock_settime (2))
339may cause
340.BR read (2)
341to unblock, but return a value of 0 (i.e., no bytes read),
342if the clock change occurs after the time expired,
343but before the
344.BR read (2)
345on the file descriptor.
45b81c9c
MK
346.TP
347.BR poll "(2), " select "(2) (and similar)"
348The file descriptor is readable
349(the
350.BR select (2)
351.I readfds
352argument; the
353.BR poll (2)
354.B POLLIN
355flag)
356if one or more timer expirations have occurred.
357.IP
358The file descriptor also supports the other file-descriptor
359multiplexing APIs:
360.BR pselect (2),
361.BR ppoll (2),
362and
363.BR epoll (7).
364.TP
6614e292 365.BR ioctl (2)
80d27367
MK
366The following timerfd-specific command is supported:
367.RS
368.TP
40f6b649
MK
369.BR TFD_IOC_SET_TICKS " (since Linux 3.17)"
370.\" commit 5442e9fbd7c23172a1c9bc736629cd123a9923f0
80d27367
MK
371Adjust the number of timer expirations that have occurred.
372The argument is a pointer to a nonzero 8-byte integer
5a3eb9cd
CG
373.RI ( uint64_t *)
374containing the new number of expirations.
80d27367 375Once the number is set, any waiter on the timer is woken up.
5a3eb9cd 376The only purpose of this command is to restore the expirations
80d27367
MK
377for the purpose of checkpoint/restore.
378This operation is available only if the kernel was configured with the
5a3eb9cd 379.BR CONFIG_CHECKPOINT_RESTORE
80d27367
MK
380option.
381.RE
5a3eb9cd 382.TP
45b81c9c
MK
383.BR close (2)
384When the file descriptor is no longer required it should be closed.
385When all file descriptors associated with the same timer object
386have been closed,
387the timer is disarmed and its resources are freed by the kernel.
388.\"
389.SS fork(2) semantics
390After a
391.BR fork (2),
392the child inherits a copy of the file descriptor created by
393.BR timerfd_create ().
394The file descriptor refers to the same underlying
395timer object as the corresponding file descriptor in the parent,
396and
397.BR read (2)s
398in the child will return information about
399expirations of the timer.
400.\"
401.SS execve(2) semantics
402A file descriptor created by
403.BR timerfd_create ()
404is preserved across
405.BR execve (2),
406and continues to generate timer expirations if the timer was armed.
47297adb 407.SH RETURN VALUE
45b81c9c
MK
408On success,
409.BR timerfd_create ()
410returns a new file descriptor.
411On error, \-1 is returned and
412.I errno
413is set to indicate the error.
efeece04 414.PP
45b81c9c
MK
415.BR timerfd_settime ()
416and
417.BR timerfd_gettime ()
418return 0 on success;
419on error they return \-1, and set
420.I errno
421to indicate the error.
422.SH ERRORS
423.BR timerfd_create ()
424can fail with the following errors:
425.TP
426.B EINVAL
427The
428.I clockid
04e2e313 429is not valid.
3df1b973
MK
430.TP
431.B EINVAL
432.I flags
433is invalid;
434or, in Linux 2.6.26 or earlier,
45b81c9c 435.I flags
c7094399 436is nonzero.
45b81c9c
MK
437.TP
438.B EMFILE
26c32fab 439The per-process limit on the number of open file descriptors has been reached.
45b81c9c
MK
440.TP
441.B ENFILE
442The system-wide limit on the total number of open files has been
443reached.
444.TP
445.B ENODEV
446Could not mount (internal) anonymous inode device.
447.TP
448.B ENOMEM
449There was insufficient kernel memory to create the timer.
96d951a4
MK
450.TP
451.B EPERM
452.I clockid
453was
454.BR CLOCK_REALTIME_ALARM
455or
456,BR CLOCK_BOOTTIME_ALARM
457but the caller did not have the
458.BR CAP_WAKE_ALARM
459capability.
45b81c9c
MK
460.PP
461.BR timerfd_settime ()
462and
463.BR timerfd_gettime ()
464can fail with the following errors:
465.TP
466.B EBADF
467.I fd
468is not a valid file descriptor.
469.TP
2bbb3907
MK
470.B EFAULT
471.IR new_value ,
472.IR old_value ,
473or
474.I curr_value
475is not valid a pointer.
476.TP
45b81c9c
MK
477.B EINVAL
478.I fd
479is not a valid timerfd file descriptor.
c71b054d
MK
480.PP
481.BR timerfd_settime ()
482can also fail with the following errors:
483.TP
0f1553b5
MK
484.B ECANCELED
485See NOTES.
486.TP
c71b054d 487.B EINVAL
45b81c9c
MK
488.I new_value
489is not properly initialized (one of the
490.I tv_nsec
491falls outside the range zero to 999,999,999).
86d95cf2
MK
492.TP
493.B EINVAL
494.\" This case only checked since 2.6.29, and 2.2.2[78].some-stable-version.
495.\" In older kernel versions, no check was made for invalid flags.
496.I flags
497is invalid.
45b81c9c
MK
498.SH VERSIONS
499These system calls are available on Linux since kernel 2.6.25.
d6a54d42 500Library support is provided by glibc since version 2.8.
45b81c9c
MK
501.SH CONFORMING TO
502These system calls are Linux-specific.
0f1553b5
MK
503.SH NOTES
504Suppose the following scenario for
505.BR CLOCK_REALTIME
506or
507.BR CLOCK_REALTIME_ALARM
508timer that was created with
509.BR timerfd_create ():
510.IP (a) 4
511The timer has been started
512.RB ( timerfd_settime ())
513with the
514.BR TFD_TIMER_ABSTIME
515and
516.BR TFD_TIMER_CANCEL_ON_SET
517flags;
518.IP (b)
519A discontinuous change (e.g.
520.BR settimeofday (2))
521is subsequently made to the
522.BR CLOCK_REALTIME
523clock; and
524.IP (c)
525the caller once more calls
526.BR timerfd_settime ()
527to rearm the timer (without first doing a
528.BR read (2)
529on the file descriptor).
530.PP
531In this case the following occurs:
532.IP \(bu 2
533The
534.BR timerfd_settime ()
535returns \-1 with
536.I errno
537set to
538.BR ECANCELED .
539(This enables the caller to know that the previous timer was affected
540by a discontinuous change to the clock.)
541.IP \(bu
542The timer
543.I "is successfully rearmed"
544with the settings provided in the second
545.BR timerfd_settime ()
546call.
547(This was probably an implementation accident, but won't be fixed now,
548in case there are applications that depend on this behaviour.)
7484d5a7
MK
549.SH BUGS
550Currently,
551.\" 2.6.29
552.BR timerfd_create ()
553supports fewer types of clock IDs than
554.BR timer_create (2).
45b81c9c
MK
555.SH EXAMPLE
556The following program creates a timer and then monitors its progress.
557The program accepts up to three command-line arguments.
558The first argument specifies the number of seconds for
559the initial expiration of the timer.
560The second argument specifies the interval for the timer, in seconds.
561The third argument specifies the number of times the program should
562allow the timer to expire before terminating.
563The second and third command-line arguments are optional.
efeece04 564.PP
45b81c9c 565The following shell session demonstrates the use of the program:
e646a1ba 566.PP
45b81c9c 567.in +4n
e646a1ba 568.EX
b43a3b30 569.RB "$" " a.out 3 1 100"
45b81c9c
MK
5700.000: timer started
5713.000: read: 1; total=1
5724.000: read: 1; total=2
b43a3b30 573.BR "^Z " " # type control-Z to suspend the program"
45b81c9c 574[1]+ Stopped ./timerfd3_demo 3 1 100
b43a3b30 575.RB "$ " "fg" " # Resume execution after a few seconds"
45b81c9c
MK
576a.out 3 1 100
5779.660: read: 5; total=7
57810.000: read: 1; total=8
57911.000: read: 1; total=9
b43a3b30 580.BR "^C " " # type control-C to suspend the program"
b8302363 581.EE
45b81c9c 582.in
9c330504 583.SS Program source
d84d0300 584\&
e7d0bb47 585.EX
45b81c9c
MK
586.\" The commented out code here is what we currently need until
587.\" the required stuff is in glibc
588.\"
589.\"
590.\"/* Link with -lrt */
591.\"#define _GNU_SOURCE
592.\"#include <sys/syscall.h>
593.\"#include <unistd.h>
594.\"#include <time.h>
595.\"#if defined(__i386__)
596.\"#define __NR_timerfd_create 322
597.\"#define __NR_timerfd_settime 325
598.\"#define __NR_timerfd_gettime 326
599.\"#endif
600.\"
601.\"static int
602.\"timerfd_create(int clockid, int flags)
603.\"{
604.\" return syscall(__NR_timerfd_create, clockid, flags);
605.\"}
606.\"
607.\"static int
608.\"timerfd_settime(int fd, int flags, struct itimerspec *new_value,
609.\" struct itimerspec *curr_value)
610.\"{
611.\" return syscall(__NR_timerfd_settime, fd, flags, new_value,
612.\" curr_value);
613.\"}
614.\"
615.\"static int
616.\"timerfd_gettime(int fd, struct itimerspec *curr_value)
617.\"{
618.\" return syscall(__NR_timerfd_gettime, fd, curr_value);
619.\"}
620.\"
621.\"#define TFD_TIMER_ABSTIME (1 << 0)
622.\"
623.\"////////////////////////////////////////////////////////////
45b81c9c
MK
624#include <sys/timerfd.h>
625#include <time.h>
626#include <unistd.h>
627#include <stdlib.h>
628#include <stdio.h>
629#include <stdint.h> /* Definition of uint64_t */
630
d1a71985 631#define handle_error(msg) \e
45b81c9c
MK
632 do { perror(msg); exit(EXIT_FAILURE); } while (0)
633
634static void
635print_elapsed_time(void)
636{
637 static struct timespec start;
638 struct timespec curr;
639 static int first_call = 1;
640 int secs, nsecs;
641
642 if (first_call) {
643 first_call = 0;
644 if (clock_gettime(CLOCK_MONOTONIC, &start) == \-1)
645 handle_error("clock_gettime");
646 }
647
648 if (clock_gettime(CLOCK_MONOTONIC, &curr) == \-1)
649 handle_error("clock_gettime");
650
651 secs = curr.tv_sec \- start.tv_sec;
652 nsecs = curr.tv_nsec \- start.tv_nsec;
653 if (nsecs < 0) {
654 secs\-\-;
655 nsecs += 1000000000;
656 }
657 printf("%d.%03d: ", secs, (nsecs + 500000) / 1000000);
658}
659
660int
661main(int argc, char *argv[])
662{
663 struct itimerspec new_value;
664 int max_exp, fd;
665 struct timespec now;
666 uint64_t exp, tot_exp;
667 ssize_t s;
668
669 if ((argc != 2) && (argc != 4)) {
d1a71985 670 fprintf(stderr, "%s init\-secs [interval\-secs max\-exp]\en",
45b81c9c
MK
671 argv[0]);
672 exit(EXIT_FAILURE);
673 }
674
675 if (clock_gettime(CLOCK_REALTIME, &now) == \-1)
676 handle_error("clock_gettime");
677
678 /* Create a CLOCK_REALTIME absolute timer with initial
679 expiration and interval as specified in command line */
680
681 new_value.it_value.tv_sec = now.tv_sec + atoi(argv[1]);
682 new_value.it_value.tv_nsec = now.tv_nsec;
683 if (argc == 2) {
684 new_value.it_interval.tv_sec = 0;
685 max_exp = 1;
686 } else {
687 new_value.it_interval.tv_sec = atoi(argv[2]);
688 max_exp = atoi(argv[3]);
689 }
690 new_value.it_interval.tv_nsec = 0;
691
692 fd = timerfd_create(CLOCK_REALTIME, 0);
693 if (fd == \-1)
694 handle_error("timerfd_create");
695
a279595b 696 if (timerfd_settime(fd, TFD_TIMER_ABSTIME, &new_value, NULL) == \-1)
45b81c9c
MK
697 handle_error("timerfd_settime");
698
699 print_elapsed_time();
d1a71985 700 printf("timer started\en");
45b81c9c
MK
701
702 for (tot_exp = 0; tot_exp < max_exp;) {
703 s = read(fd, &exp, sizeof(uint64_t));
704 if (s != sizeof(uint64_t))
705 handle_error("read");
706
707 tot_exp += exp;
708 print_elapsed_time();
d1a71985 709 printf("read: %llu; total=%llu\en",
45b81c9c
MK
710 (unsigned long long) exp,
711 (unsigned long long) tot_exp);
712 }
713
714 exit(EXIT_SUCCESS);
715}
e7d0bb47 716.EE
47297adb 717.SH SEE ALSO
45b81c9c
MK
718.BR eventfd (2),
719.BR poll (2),
720.BR read (2),
721.BR select (2),
722.BR setitimer (2),
723.BR signalfd (2),
804f03e6
MK
724.BR timer_create (2),
725.BR timer_gettime (2),
726.BR timer_settime (2),
45b81c9c
MK
727.BR epoll (7),
728.BR time (7)