diff options
Diffstat (limited to 'arch/x86/kernel/tsc.c')
-rw-r--r-- | arch/x86/kernel/tsc.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index ef4dac50143f..6e1a368d21d4 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c | |||
@@ -9,6 +9,7 @@ | |||
9 | #include <linux/delay.h> | 9 | #include <linux/delay.h> |
10 | #include <linux/clocksource.h> | 10 | #include <linux/clocksource.h> |
11 | #include <linux/percpu.h> | 11 | #include <linux/percpu.h> |
12 | #include <linux/timex.h> | ||
12 | 13 | ||
13 | #include <asm/hpet.h> | 14 | #include <asm/hpet.h> |
14 | #include <asm/timer.h> | 15 | #include <asm/timer.h> |
@@ -635,17 +636,15 @@ static int time_cpufreq_notifier(struct notifier_block *nb, unsigned long val, | |||
635 | void *data) | 636 | void *data) |
636 | { | 637 | { |
637 | struct cpufreq_freqs *freq = data; | 638 | struct cpufreq_freqs *freq = data; |
638 | unsigned long *lpj, dummy; | 639 | unsigned long *lpj; |
639 | 640 | ||
640 | if (cpu_has(&cpu_data(freq->cpu), X86_FEATURE_CONSTANT_TSC)) | 641 | if (cpu_has(&cpu_data(freq->cpu), X86_FEATURE_CONSTANT_TSC)) |
641 | return 0; | 642 | return 0; |
642 | 643 | ||
643 | lpj = &dummy; | 644 | lpj = &boot_cpu_data.loops_per_jiffy; |
644 | if (!(freq->flags & CPUFREQ_CONST_LOOPS)) | ||
645 | #ifdef CONFIG_SMP | 645 | #ifdef CONFIG_SMP |
646 | if (!(freq->flags & CPUFREQ_CONST_LOOPS)) | ||
646 | lpj = &cpu_data(freq->cpu).loops_per_jiffy; | 647 | lpj = &cpu_data(freq->cpu).loops_per_jiffy; |
647 | #else | ||
648 | lpj = &boot_cpu_data.loops_per_jiffy; | ||
649 | #endif | 648 | #endif |
650 | 649 | ||
651 | if (!ref_freq) { | 650 | if (!ref_freq) { |