From f086b6aad1bdb9fedc54172bfa9e36a49820159f Mon Sep 17 00:00:00 2001 From: Michael Kerrisk Date: Tue, 13 Dec 2016 09:09:44 +0100 Subject: [PATCH] clock_getres.2: Note POSIX.1 requirements re relative time services and CLOCK_REALTIME Signed-off-by: Michael Kerrisk --- man2/clock_getres.2 | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/man2/clock_getres.2 b/man2/clock_getres.2 index 2949df5a6..6e2e49411 100644 --- a/man2/clock_getres.2 +++ b/man2/clock_getres.2 @@ -243,6 +243,20 @@ are available. (See also .BR sysconf (3).) .SH NOTES +POSIX.1 specifies the following: +.RS +.PP +Setting the value of the +.B CLOCK_REALTIME +clock via +.BR clock_settime (2) +shall have no effect on threads that are blocked waiting for a relative time +service based upon this clock, including the +.BR nanosleep () +function; nor on the expiration of relative timers based upon this clock. +Consequently, these time services shall expire when the requested relative +interval elapses, independently of the new or old value of the clock. +.\" .SS Historical note for SMP systems Before Linux added kernel support for .B CLOCK_PROCESS_CPUTIME_ID