aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/apic_64.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2008-01-30 07:33:04 -0500
committerIngo Molnar <mingo@elte.hu>2008-01-30 07:33:04 -0500
commitc2b84b30b8c8bbccf4d2e32f8a3a70ad09ba9ab8 (patch)
treedb749014619fdef88cf458daad810ddd06023fe7 /arch/x86/kernel/apic_64.c
parent387faedb1dee2e917811acd05902cc36142a4850 (diff)
x86: sanity check APIC timer frequency
Check the APIC timer calibration result for sanity. When the frequency is out of range, issue a warning and disable the local APIC timer. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/apic_64.c')
-rw-r--r--arch/x86/kernel/apic_64.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/x86/kernel/apic_64.c b/arch/x86/kernel/apic_64.c
index d1a696673d9d..731b48660fc4 100644
--- a/arch/x86/kernel/apic_64.c
+++ b/arch/x86/kernel/apic_64.c
@@ -384,6 +384,18 @@ void __init setup_boot_APIC_clock(void)
384 calibrate_APIC_clock(); 384 calibrate_APIC_clock();
385 385
386 /* 386 /*
387 * Do a sanity check on the APIC calibration result
388 */
389 if (calibration_result < (1000000 / HZ)) {
390 printk(KERN_WARNING
391 "APIC frequency too slow, disabling apic timer\n");
392 /* No broadcast on UP ! */
393 if (num_possible_cpus() > 1)
394 setup_APIC_timer();
395 return;
396 }
397
398 /*
387 * If nmi_watchdog is set to IO_APIC, we need the 399 * If nmi_watchdog is set to IO_APIC, we need the
388 * PIT/HPET going. Otherwise register lapic as a dummy 400 * PIT/HPET going. Otherwise register lapic as a dummy
389 * device. 401 * device.