and
.I tp
arguments are
-.I timespec
-structures, as specified in
-.IR <time.h> :
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+.BR timespec (3)
+structures.
.PP
The
.I clockid
.BR ftime (3),
.BR pthread_getcpuclockid (3),
.BR sysconf (3),
+.BR timespec (3),
.BR time (7),
.BR time_namespaces (7),
.BR vdso (7),
either an absolute or a relative value.
.PP
The time values passed to and returned by this call are specified using
-.I timespec
-structures, defined as follows:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds [0 .. 999999999] */
-};
-.EE
-.in
+.BR timespec (3)
+structures.
.PP
The
.I clockid
.BR restart_syscall (2),
.BR timer_create (2),
.BR sleep (3),
+.BR timespec (3),
.BR usleep (3),
.BR time (7)
specified by \fIctx_id\fP.
.PP
The \fItimeout\fP argument specifies the amount of time to wait for events,
-and is specified as a relative timeout in a structure of the following form:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds [0 .. 999999999] */
-};
-.EE
-.in
+and is specified as a relative timeout in a
+.BR timespec (3)
+structure.
.PP
The specified time will be rounded up to the system clock granularity
and is guaranteed not to expire early.
.BR io_destroy (2),
.BR io_setup (2),
.BR io_submit (2),
+.BR timespec (3),
.BR aio (7),
.BR time (7)
.\" .SH AUTHOR
.BR nanosleep ()
again and complete the specified pause (but see NOTES).
.PP
-The structure
-.I timespec
+The
+.BR timespec (3)
+structure
is used to specify intervals of time with nanosecond precision.
-It is defined as follows:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
.PP
The value of the nanoseconds field must be in the range 0 to 999999999.
.PP
.BR sched_setscheduler (2),
.BR timer_create (2),
.BR sleep (3),
+.BR timespec (3),
.BR usleep (3),
.BR time (7)
argument specifies an upper limit on the amount of time that
.BR ppoll ()
will block.
-This argument is a pointer to a structure of the following form:
-.PP
-.in +4n
-.EX
-struct timespec {
- long tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+This argument is a pointer to a
+.BR timespec (3)
+structure.
.PP
If
.I tmo_p
.BR restart_syscall (2),
.BR select (2),
.BR select_tut (2),
+.BR timespec (3),
.BR epoll (7),
.BR time (7)
.SH DESCRIPTION
.BR sched_rr_get_interval ()
writes into the
-.I timespec
+.BR timespec (3)
structure pointed to by
.I tp
the round-robin time quantum for the process identified by
.B SCHED_RR
scheduling policy.
.PP
-The
-.I timespec
-structure has the following form:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
-.PP
If
.I pid
is zero, the time quantum for the calling process is written into
.\" ENOSYS, because SCHED_RR has not yet been fully implemented and tested
.\" properly.
.SH SEE ALSO
+.BR timespec (3),
.BR sched (7)
.PP
The corresponding argument for
.BR pselect ()
-has the following type:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+is a
+.BR timespec (3)
+structure.
.PP
On Linux,
.BR select ()
.BR send (2),
.BR sigprocmask (2),
.BR write (2),
+.BR timespec (3),
.BR epoll (7),
.BR time (7)
.PP
(This interval will be rounded up to the system clock granularity,
and kernel scheduling delays mean that the interval
may overrun by a small amount.)
-This argument is of the following type:
-.PP
-.in +4n
-.EX
-struct timespec {
- long tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-}
-.EE
-.in
+This argument is a
+.BR timespec (3)
+structure.
.PP
If both fields of this structure are specified as 0, a poll is performed:
.BR sigtimedwait ()
.BR sigqueue (3),
.BR sigsetops (3),
.BR sigwait (3),
+.BR timespec (3),
.BR signal (7),
.BR time (7)
.PP
.in +4n
.EX
-struct timespec {
- time_t tv_sec; /* Seconds */
- long tv_nsec; /* Nanoseconds */
-};
-
struct itimerspec {
struct timespec it_interval; /* Timer interval */
struct timespec it_value; /* Initial expiration */
Each of the substructures of the
.I itimerspec
structure is a
-.I timespec
+.BR timespec (3)
structure that allows a time value to be specified
in seconds and nanoseconds.
These time values are measured according to the clock
.SH SEE ALSO
.BR timer_create (2),
.BR timer_getoverrun (2),
+.BR timespec (3),
.BR time (7)
The
.I itimerspec
structure used for this argument contains two fields,
-each of which is in turn a structure of type
-.IR timespec :
+each of which is in turn a
+.BR timespec (3)
+structure:
.PP
.in +4n
.EX
-struct timespec {
- time_t tv_sec; /* Seconds */
- long tv_nsec; /* Nanoseconds */
-};
-
struct itimerspec {
struct timespec it_interval; /* Interval for periodic timer */
struct timespec it_value; /* Initial expiration */
.BR timer_create (2),
.BR timer_gettime (2),
.BR timer_settime (2),
+.BR timespec (3),
.BR epoll (7),
.BR time (7)
.I times
specifies a time as the number of seconds and nanoseconds
since the Epoch, 1970-01-01 00:00:00 +0000 (UTC).
-This information is conveyed in a structure of the following form:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+This information is conveyed in a
+.BR timespec (3)
+structure.
.PP
Updated file timestamps are set to the greatest value
supported by the filesystem that is not greater than the specified time.
.BR stat (2),
.BR utimes (2),
.BR futimes (3),
+.BR timespec (3),
.BR inode (7),
.BR path_resolution (7),
.BR symlink (7)
points to a structure which specifies how long the call will block.
This value is an absolute timeout in seconds and nanoseconds
since the Epoch, 1970-01-01 00:00:00 +0000 (UTC),
-specified in the following structure:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+specified in a
+.BR timespec (3)
+structure.
.PP
If no message is available,
and the timeout has already expired by the time of the call,
.BR mq_open (3),
.BR mq_send (3),
.BR mq_unlink (3),
+.BR timespec (3),
.BR mq_overview (7),
.BR time (7)
points to a structure which specifies how long the call will block.
This value is an absolute timeout in seconds and nanoseconds
since the Epoch, 1970-01-01 00:00:00 +0000 (UTC),
-specified in the following structure:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+specified in a
+.BR timespec (3)
+structure.
.PP
If the message queue is full,
and the timeout has already expired by the time of the call,
.BR mq_open (3),
.BR mq_receive (3),
.BR mq_unlink (3),
+.BR timespec (3),
.BR mq_overview (7),
.BR time (7)
the call returns an error.
The
.I abstime
-argument is a structure of the following form,
+argument is a
+.BR timespec (3)
+structure,
specifying an absolute time measured since the Epoch (see
-.BR time (2)):
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* seconds */
- long tv_nsec; /* nanoseconds */
-};
-.EE
-.in
+.BR time (2)).
.SH RETURN VALUE
On success,
these functions return 0;
.BR clock_gettime (2),
.BR pthread_exit (3),
.BR pthread_join (3),
+.BR timespec (3),
.BR pthreads (7)
should block if the decrement cannot be immediately performed.
The
.I abs_timeout
-argument points to a structure that specifies an absolute timeout
+argument points to a
+.BR timespec (3)
+structure that specifies an absolute timeout
in seconds and nanoseconds since the Epoch, 1970-01-01 00:00:00 +0000 (UTC).
-This structure is defined as follows:
-.PP
-.in +4n
-.EX
-struct timespec {
- time_t tv_sec; /* Seconds */
- long tv_nsec; /* Nanoseconds [0 .. 999999999] */
-};
-.EE
-.in
.PP
If the timeout has already expired by the time of the call,
and the semaphore could not be locked immediately,
.BR clock_gettime (2),
.BR sem_getvalue (3),
.BR sem_post (3),
+.BR timespec (3),
.BR sem_overview (7),
.BR time (7)