]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] x86_64: Fix drift with HPET timer enabled
authorJordan Hargrave <jordan_hargrave@dell.com>
Fri, 7 Apr 2006 17:50:18 +0000 (19:50 +0200)
committerLinus Torvalds <torvalds@g5.osdl.org>
Sun, 9 Apr 2006 18:53:53 +0000 (11:53 -0700)
commitb04700494b6d1a99dedbec329916dfd36220b199
tree8624096baed40f8f89e757b2d170a7b4d1844575
parentee1eef067907bebaba46db77c7c672e569d2139c
[PATCH] x86_64: Fix drift with HPET timer enabled

If the HPET timer is enabled, the clock can drift by ~3 seconds a day.
This is due to the HPET timer not being initialized with the correct
setting (still using PIT count).

If HZ changes, this drift can become even more pronounced.

HPET patch initializes tick_nsec with correct tick_nsec settings for
HPET timer.

Vojtech comments:

  "It's not entirely correct (it assumes the HPET ticks totally
   exactly), but it's significantly better than assuming the PIT error
   there."

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/x86_64/kernel/time.c
include/asm-i386/hpet.h
include/asm-x86_64/hpet.h
include/linux/jiffies.h
kernel/timer.c