diff options
author | phk <phk@FreeBSD.org> | 1999-03-08 12:36:14 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-03-08 12:36:14 +0000 |
commit | 64517141512ea425006e955c5b7e758c17d9afba (patch) | |
tree | 25786d7a5907899e7ab54f3cc1c250eb88fd000b /sys/kern/kern_tc.c | |
parent | ff9dd97ed39dc95f8f88fa41cc7f2c313ae47c72 (diff) | |
download | FreeBSD-src-64517141512ea425006e955c5b7e758c17d9afba.zip FreeBSD-src-64517141512ea425006e955c5b7e758c17d9afba.tar.gz |
Integrate the new "nanokernel" PLL from Dave Mills.
This code is backwards compatible with the older "microkernel" PLL, but
allows ntpd v4 to use nanosecond resolution. Many other improvements.
PPS_SYNC and hardpps() are NOT supported yet.
Diffstat (limited to 'sys/kern/kern_tc.c')
-rw-r--r-- | sys/kern/kern_tc.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c index 0b35622..1c536ee 100644 --- a/sys/kern/kern_tc.c +++ b/sys/kern/kern_tc.c @@ -37,7 +37,7 @@ * SUCH DAMAGE. * * @(#)kern_clock.c 8.5 (Berkeley) 1/21/94 - * $Id: kern_clock.c,v 1.87 1999/02/19 14:25:34 luoqi Exp $ + * $Id: kern_clock.c,v 1.88 1999/02/19 19:34:49 luoqi Exp $ */ #include <sys/param.h> @@ -675,10 +675,7 @@ tco_setscales(struct timecounter *tc) u_int64_t scale; scale = 1000000000LL << 32; - if (tc->tc_adjustment > 0) - scale += (tc->tc_adjustment * 1000LL) << 10; - else - scale -= (-tc->tc_adjustment * 1000LL) << 10; + scale += tc->tc_adjustment; scale /= tc->tc_frequency; tc->tc_scale_micro = scale / 1000; tc->tc_scale_nano_f = scale & 0xffffffff; |