From 01d49466d2a94135ff238f0422a7b78cd656ac63 Mon Sep 17 00:00:00 2001 From: Ted Unangst Date: Fri, 13 Jan 2006 22:02:38 +0000 Subject: auto adjusting adjtime. be more responsive to large clock deltas, and attempt to compensate for incorrect clocks by adjusting ticks slowly. ok deraadt --- sys/kern/kern_clock.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sys/kern/kern_clock.c') diff --git a/sys/kern/kern_clock.c b/sys/kern/kern_clock.c index 9f494c8bdf3..b6256ec42ca 100644 --- a/sys/kern/kern_clock.c +++ b/sys/kern/kern_clock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_clock.c,v 1.56 2006/01/03 18:22:31 miod Exp $ */ +/* $OpenBSD: kern_clock.c,v 1.57 2006/01/13 22:02:37 tedu Exp $ */ /* $NetBSD: kern_clock.c,v 1.34 1996/06/09 04:51:03 briggs Exp $ */ /*- @@ -220,6 +220,7 @@ hardclock(struct clockframe *frame) struct proc *p; #ifndef __HAVE_TIMECOUNTER int delta; + extern int tick_skew; extern int tickdelta; extern long timedelta; #endif @@ -272,7 +273,7 @@ hardclock(struct clockframe *frame) * ``tickdelta'' may also be added in. */ - delta = tick; + delta = tick + tick_skew; if (tickfix) { tickfixcnt += tickfix; -- cgit v1.2.3