mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Linux exports HZ value to user space via AT_CLKTCK auxiliary vector entry,
which is available for Glibc as sysconf(_SC_CLK_TCK). If AT_CLKTCK entry is not exported, Glibc uses 100. linux_times() shall use the value that is exported to user space. Pointyhat to: dchagin PR: kern/134251 Approved by: kib (mentor) MFC after: 2 weeks
This commit is contained in:
parent
46b303e83d
commit
c65b9bfa3c
1 changed files with 1 additions and 3 deletions
|
|
@ -659,9 +659,7 @@ struct l_times_argv {
|
|||
l_clock_t tms_cstime;
|
||||
};
|
||||
|
||||
#define CLK_TCK 100 /* Linux uses 100 */
|
||||
|
||||
#define CONVTCK(r) (r.tv_sec * CLK_TCK + r.tv_usec / (1000000 / CLK_TCK))
|
||||
#define CONVTCK(r) (r.tv_sec * hz + r.tv_usec / (1000000 / hz))
|
||||
|
||||
int
|
||||
linux_times(struct thread *td, struct linux_times_args *args)
|
||||
|
|
|
|||
Loading…
Reference in a new issue