Document additional CLOCK_* values in glibc manual
- Backport: Document all CLOCK_* values Resolves: RHEL-57587
This commit is contained in:
parent
77127fa642
commit
0ee649ca74
65
glibc-RHEL-57587.patch
Normal file
65
glibc-RHEL-57587.patch
Normal file
@ -0,0 +1,65 @@
|
||||
commit f451a02a8c3c0bc6b41dac5e9e6ad49dd1c9529c
|
||||
Author: Joseph Myers <josmyers@redhat.com>
|
||||
Date: Mon May 12 14:56:07 2025 +0000
|
||||
|
||||
Document all CLOCK_* values
|
||||
|
||||
The manual documents CLOCK_REALTIME and CLOCK_MONOTONIC but not other
|
||||
CLOCK_* values. Add documentation of the POSIX clocks
|
||||
CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID, along with a
|
||||
reference to the Linux man pages for the semantics of the
|
||||
Linux-specific clocks supported (as with some other functionality
|
||||
coming direct from the Linux kernel where the man pages can be
|
||||
considered the main documentation).
|
||||
|
||||
Note: CLOCK_MONOTONIC_RAW, CLOCK_REALTIME_COARSE and
|
||||
CLOCK_MONOTONIC_COARSE are also defined in the toplevel bits/time.h,
|
||||
as used for Hurd. Nevertheless, I see no sign that the Hurd code in
|
||||
glibc actually has any support for those clocks, so I think it is
|
||||
correct to document them as Linux-specific (and to refer only to the
|
||||
Linux man pages for their semantics).
|
||||
|
||||
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
|
||||
|
||||
diff --git a/manual/time.texi b/manual/time.texi
|
||||
index c0e645b15ce44788..8e072c7e375a750e 100644
|
||||
--- a/manual/time.texi
|
||||
+++ b/manual/time.texi
|
||||
@@ -528,7 +528,36 @@ Therefore, @code{CLOCK_MONOTONIC} cannot be used to measure
|
||||
absolute time, only elapsed time.
|
||||
@end deftypevr
|
||||
|
||||
-Systems may support more than just these two POSIX clocks.
|
||||
+The following clocks are defined by POSIX, but may not be supported by
|
||||
+all POSIX systems:
|
||||
+
|
||||
+@deftypevr Macro clockid_t CLOCK_PROCESS_CPUTIME_ID
|
||||
+@standards{POSIX.1, time.h}
|
||||
+This POSIX clock measures the amount of CPU time used by the calling
|
||||
+process.
|
||||
+@end deftypevr
|
||||
+
|
||||
+@deftypevr Macro clockid_t CLOCK_THREAD_CPUTIME_ID
|
||||
+@standards{POSIX.1, time.h}
|
||||
+This POSIX clock measures the amount of CPU time used by the calling
|
||||
+thread.
|
||||
+@end deftypevr
|
||||
+
|
||||
+The following clocks are Linux extensions:
|
||||
+
|
||||
+@deftypevr Macro clockid_t CLOCK_MONOTONIC_RAW
|
||||
+@deftypevrx Macro clockid_t CLOCK_REALTIME_COARSE
|
||||
+@deftypevrx Macro clockid_t CLOCK_MONOTONIC_COARSE
|
||||
+@deftypevrx Macro clockid_t CLOCK_BOOTTIME
|
||||
+@deftypevrx Macro clockid_t CLOCK_REALTIME_ALARM
|
||||
+@deftypevrx Macro clockid_t CLOCK_BOOTTIME_ALARM
|
||||
+@deftypevrx Macro clockid_t CLOCK_TAI
|
||||
+@standards{Linux, time.h}
|
||||
+For details of these clocks, see the manual page
|
||||
+@manpageurl{clock_gettime,2}.
|
||||
+@end deftypevr
|
||||
+
|
||||
+Systems may support additional clocks beyond those listed here.
|
||||
|
||||
@deftypefun int clock_gettime (clockid_t @var{clock}, struct timespec *@var{ts})
|
||||
@standards{POSIX.1, time.h}
|
||||
@ -157,7 +157,7 @@ end \
|
||||
Summary: The GNU libc libraries
|
||||
Name: glibc
|
||||
Version: %{glibcversion}
|
||||
Release: 197%{?dist}
|
||||
Release: 198%{?dist}
|
||||
|
||||
# In general, GPLv2+ is used by programs, LGPLv2+ is used for
|
||||
# libraries.
|
||||
@ -1215,6 +1215,7 @@ Patch906: glibc-RHEL-92697-6.patch
|
||||
Patch907: glibc-RHEL-92697-8.patch
|
||||
Patch908: glibc-RHEL-92697-9.patch
|
||||
Patch909: glibc-RHEL-92095.patch
|
||||
Patch910: glibc-RHEL-57587.patch
|
||||
|
||||
##############################################################################
|
||||
# Continued list of core "glibc" package information:
|
||||
@ -3208,6 +3209,9 @@ update_gconv_modules_cache ()
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Mon May 26 2025 Frédéric Bérat <fberat@redhat.com> - 2.34-198
|
||||
- Document additional CLOCK_* values in glibc manual (RHEL-57587)
|
||||
|
||||
* Thu May 22 2025 Frédéric Bérat <fberat@redhat.com> - 2.34-197
|
||||
- Prevent `,ccs=` from being treated as individual mode flags in `fopen` calls
|
||||
(RHEL-92095)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user