Tag: KERNEL-2-2-18-PRE11-PATCH-17 Patch: tsc-calibration-non-compile-time-1 From: Andrea Arcangeli TSC calibration must be dynamic and not a compile time thing because gettimeofday is dynamic and it depends on the TSCs to be in sync. Index: linux/arch/i386/kernel/smp.c diff -u linux/arch/i386/kernel/smp.c:1.3.6.1 linux/arch/i386/kernel/smp.c:1.3.6.2 --- linux/arch/i386/kernel/smp.c:1.3.6.1 Wed Sep 27 23:54:02 2000 +++ linux/arch/i386/kernel/smp.c Thu Sep 28 00:03:31 2000 @@ -795,7 +795,6 @@ return memory_start; } -#ifdef CONFIG_X86_TSC /* * TSC synchronization. * @@ -995,8 +994,6 @@ } #undef NR_LOOPS -#endif - extern void calibrate_delay(void); void __init smp_callin(void) @@ -1083,12 +1080,11 @@ */ set_bit(cpuid, (unsigned long *)&cpu_callin_map[0]); -#ifdef CONFIG_X86_TSC /* * Synchronize the TSC with the BP */ - synchronize_tsc_ap (); -#endif + if (boot_cpu_data.x86_capability & X86_FEATURE_TSC) + synchronize_tsc_ap (); } int cpucount = 0; @@ -1624,13 +1620,11 @@ smp_done: -#ifdef CONFIG_X86_TSC /* * Synchronize the TSC with the AP */ - if (cpucount) + if (boot_cpu_data.x86_capability & X86_FEATURE_TSC && cpucount) synchronize_tsc_bp(); -#endif } /*