]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] x86_64: fix last_tsc calculation of PM timer
authorJan Beulich <jbeulich@novell.com>
Tue, 30 May 2006 20:47:54 +0000 (22:47 +0200)
committerLinus Torvalds <torvalds@g5.osdl.org>
Wed, 31 May 2006 03:31:05 +0000 (20:31 -0700)
commit388080618afc55902805e60ee80be756fd6708b6
tree7a48afb9933732c6fccb2baa1e928e3508a3c940
parent135e103d191fddede41135341d4679dd998802d6
[PATCH] x86_64: fix last_tsc calculation of PM timer

From: "Jan Beulich" <jbeulich@novell.com>

The PM timer code updates vxtime.last_tsc, but this update was done
incorrectly in two ways:
- offset_delay being in microseconds requires multiplying with cpu_mhz
  rather than cpu_khz
- the multiplication of offset_delay and cpu_khz (both being 32-bit
  values) on most current CPUs would overflow (observed value of the
  delay was approximately 4000us, yielding an overflow for frequencies
  starting a little above 1GHz)

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/x86_64/kernel/pmtimer.c