diff --git a/arch/x86/include/asm/tsc.h b/arch/x86/include/asm/tsc.h index 04721d54d8d9ea1a7f34d61afdf0bfc00815ae14..c054eaa7dc94109681eaa60589c97c35848fefef 100644 --- a/arch/x86/include/asm/tsc.h +++ b/arch/x86/include/asm/tsc.h @@ -45,15 +45,16 @@ extern int tsc_clocksource_reliable; * Boot-time check whether the TSCs are synchronized across * all CPUs/cores: */ -extern void check_tsc_sync_source(int cpu); -extern void check_tsc_sync_target(void); - #ifdef CONFIG_X86_TSC extern bool tsc_store_and_check_tsc_adjust(void); extern void tsc_verify_tsc_adjust(void); +extern void check_tsc_sync_source(int cpu); +extern void check_tsc_sync_target(void); #else -static inline bool tsc_store_and_check_tsc_adjust(void) { } +static inline bool tsc_store_and_check_tsc_adjust(void) { return false; } static inline void tsc_verify_tsc_adjust(void) { } +static inline void check_tsc_sync_source(int cpu) { } +static inline void check_tsc_sync_target(void) { } #endif extern int notsc_setup(char *); diff --git a/arch/x86/kernel/tsc_sync.c b/arch/x86/kernel/tsc_sync.c index d7f48a640ff5136ccacf17df6f6760cebc6ca773..8fde44f8cfec2b8e45485dda98f1527d4ece0784 100644 --- a/arch/x86/kernel/tsc_sync.c +++ b/arch/x86/kernel/tsc_sync.c @@ -61,7 +61,7 @@ void tsc_verify_tsc_adjust(void) #ifndef CONFIG_SMP bool __init tsc_store_and_check_tsc_adjust(void) { - struct tsc_adjust *ref, *cur = this_cpu_ptr(&tsc_adjust); + struct tsc_adjust *cur = this_cpu_ptr(&tsc_adjust); s64 bootval; if (!boot_cpu_has(X86_FEATURE_TSC_ADJUST))