mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-06 09:17:25 +00:00
Improve clock accuracy by accounting for late/missed clock interrupts
if the hardware supports it.
This commit is contained in:
parent
3abc79d2ee
commit
07e3b0c25b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=11451
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
|
||||
* $Id: kern_clock.c,v 1.15 1995/08/28 09:18:43 julian Exp $
|
||||
* $Id: kern_clock.c,v 1.16 1995/09/09 18:10:01 davidg Exp $
|
||||
*/
|
||||
|
||||
/* Portions of this software are covered by the following: */
|
||||
@ -477,9 +477,9 @@ hardclock(frame)
|
||||
long ltemp;
|
||||
|
||||
if (timedelta == 0) {
|
||||
time_update = tick;
|
||||
time_update = CPU_THISTICKLEN(tick);
|
||||
} else {
|
||||
time_update = tick + tickdelta;
|
||||
time_update = CPU_THISTICKLEN(tick) + tickdelta;
|
||||
timedelta -= tickdelta;
|
||||
}
|
||||
BUMPTIME(&mono_time, time_update);
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
|
||||
* $Id: kern_clock.c,v 1.15 1995/08/28 09:18:43 julian Exp $
|
||||
* $Id: kern_clock.c,v 1.16 1995/09/09 18:10:01 davidg Exp $
|
||||
*/
|
||||
|
||||
/* Portions of this software are covered by the following: */
|
||||
@ -477,9 +477,9 @@ hardclock(frame)
|
||||
long ltemp;
|
||||
|
||||
if (timedelta == 0) {
|
||||
time_update = tick;
|
||||
time_update = CPU_THISTICKLEN(tick);
|
||||
} else {
|
||||
time_update = tick + tickdelta;
|
||||
time_update = CPU_THISTICKLEN(tick) + tickdelta;
|
||||
timedelta -= tickdelta;
|
||||
}
|
||||
BUMPTIME(&mono_time, time_update);
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
|
||||
* $Id: kern_clock.c,v 1.15 1995/08/28 09:18:43 julian Exp $
|
||||
* $Id: kern_clock.c,v 1.16 1995/09/09 18:10:01 davidg Exp $
|
||||
*/
|
||||
|
||||
/* Portions of this software are covered by the following: */
|
||||
@ -477,9 +477,9 @@ hardclock(frame)
|
||||
long ltemp;
|
||||
|
||||
if (timedelta == 0) {
|
||||
time_update = tick;
|
||||
time_update = CPU_THISTICKLEN(tick);
|
||||
} else {
|
||||
time_update = tick + tickdelta;
|
||||
time_update = CPU_THISTICKLEN(tick) + tickdelta;
|
||||
timedelta -= tickdelta;
|
||||
}
|
||||
BUMPTIME(&mono_time, time_update);
|
||||
|
Loading…
Reference in New Issue
Block a user