This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/9690] New: glibc time functionality broken with kernel 2.6.26 and later
- From: "hvengel at astound dot net" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 28 Dec 2008 20:51:20 -0000
- Subject: [Bug libc/9690] New: glibc time functionality broken with kernel 2.6.26 and later
- Reply-to: sourceware-bugzilla at sourceware dot org
Kernel 2.6.26 changed it's time functionality from being microsecond based
(microkernel) to being nanosecond based (nanokernel). As a result there needs
to be changes made to sysdeps/unix/sysv/linux/sys/timex.h and also to
sysdeps/unix/sysv/linux/ntp_gettime.c to make glibc compatible with these newer
kernel versions. If this is not done ntp will not function correctly. Please
see http://sourceware.org/ml/libc-alpha/2008-03/msg00076.html for a set of
patches based on glibc 2.7 that will correct this problem.
With the current code base ntp builds for a microkernel and it's functions to
set the clocks rate will be off by 3 orders of magnitude since the kernel is
passing and expecting to get nanosecond values. This results in the clock being
unstable. This is most noticeable when using a high quality reference clock
like a GPS where it should be possible to get near microsecond offsets with a
properly functioning clock but with the current glibc code it is more typical to
see around 100 microsecond offsets with the clock slewing between positive and
negative offsets and sometimes being off by as much as 500 microseconds.
I have been using the patches from the above link for several months without
issue and these patches are being widely used by users of the LinuxPPS kernel
patch set. The LinuxPPS patch set is now appearing in the daily mm kernel
snapshots and it is highly likely that kernel 2.6.29 will be shipped with the
LinuxPPS patches. This will allow more users to attach reference clocks to
their machines and the issues with glibc and ntp and these newer kernels will
become painfully apparent when these users do not get the clock accuracy that
they were expecting.
--
Summary: glibc time functionality broken with kernel 2.6.26 and
later
Product: glibc
Version: 2.8
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: hvengel at astound dot net
CC: glibc-bugs at sources dot redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=9690
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.