diff options
Diffstat (limited to 'arch/x86/kernel/tsc.c')
-rw-r--r-- | arch/x86/kernel/tsc.c | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index c8d52cb4cb6e..c3f7602cd038 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c | |||
@@ -21,6 +21,7 @@ | |||
21 | #include <asm/hypervisor.h> | 21 | #include <asm/hypervisor.h> |
22 | #include <asm/nmi.h> | 22 | #include <asm/nmi.h> |
23 | #include <asm/x86_init.h> | 23 | #include <asm/x86_init.h> |
24 | #include <asm/geode.h> | ||
24 | 25 | ||
25 | unsigned int __read_mostly cpu_khz; /* TSC clocks / usec, not used here */ | 26 | unsigned int __read_mostly cpu_khz; /* TSC clocks / usec, not used here */ |
26 | EXPORT_SYMBOL(cpu_khz); | 27 | EXPORT_SYMBOL(cpu_khz); |
@@ -1013,15 +1014,17 @@ EXPORT_SYMBOL_GPL(mark_tsc_unstable); | |||
1013 | 1014 | ||
1014 | static void __init check_system_tsc_reliable(void) | 1015 | static void __init check_system_tsc_reliable(void) |
1015 | { | 1016 | { |
1016 | #ifdef CONFIG_MGEODE_LX | 1017 | #if defined(CONFIG_MGEODEGX1) || defined(CONFIG_MGEODE_LX) || defined(CONFIG_X86_GENERIC) |
1017 | /* RTSC counts during suspend */ | 1018 | if (is_geode_lx()) { |
1019 | /* RTSC counts during suspend */ | ||
1018 | #define RTSC_SUSP 0x100 | 1020 | #define RTSC_SUSP 0x100 |
1019 | unsigned long res_low, res_high; | 1021 | unsigned long res_low, res_high; |
1020 | 1022 | ||
1021 | rdmsr_safe(MSR_GEODE_BUSCONT_CONF0, &res_low, &res_high); | 1023 | rdmsr_safe(MSR_GEODE_BUSCONT_CONF0, &res_low, &res_high); |
1022 | /* Geode_LX - the OLPC CPU has a very reliable TSC */ | 1024 | /* Geode_LX - the OLPC CPU has a very reliable TSC */ |
1023 | if (res_low & RTSC_SUSP) | 1025 | if (res_low & RTSC_SUSP) |
1024 | tsc_clocksource_reliable = 1; | 1026 | tsc_clocksource_reliable = 1; |
1027 | } | ||
1025 | #endif | 1028 | #endif |
1026 | if (boot_cpu_has(X86_FEATURE_TSC_RELIABLE)) | 1029 | if (boot_cpu_has(X86_FEATURE_TSC_RELIABLE)) |
1027 | tsc_clocksource_reliable = 1; | 1030 | tsc_clocksource_reliable = 1; |