Re: notsc is ignored on common configurations
From: Ingo Molnar
Date: Tue Feb 19 2008 - 06:27:14 EST
* Pavel Machek <pavel@xxxxxx> wrote:
> notsc is ignored in 32-bit kernels if CONFIG_X86_TSC is on.. which is
> bad, fix it.
thanks, applied.
> -static unsigned int ref_freq = 0;
> -static unsigned long loops_per_jiffy_ref = 0;
> -static unsigned long cpu_khz_ref = 0;
> +static unsigned int ref_freq;
> +static unsigned long loops_per_jiffy_ref;
> +static unsigned long cpu_khz_ref;
i have split these changes into the separate patch below.
Ingo
---------------->
Subject: x86: clean up =0 initializations in arch/x86/kernel/tsc_32.c
From: Pavel Machek <pavel@xxxxxx>
Date: Tue, 19 Feb 2008 11:02:30 +0100
Signed-off-by: Pavel Machek <pavel@xxxxxxx>
Signed-off-by: Ingo Molnar <mingo@xxxxxxx>
---
arch/x86/kernel/tsc_32.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
Index: linux-x86.q/arch/x86/kernel/tsc_32.c
===================================================================
--- linux-x86.q.orig/arch/x86/kernel/tsc_32.c
+++ linux-x86.q/arch/x86/kernel/tsc_32.c
@@ -222,9 +222,9 @@ EXPORT_SYMBOL(recalibrate_cpu_khz);
* if the CPU frequency is scaled, TSC-based delays will need a different
* loops_per_jiffy value to function properly.
*/
-static unsigned int ref_freq = 0;
-static unsigned long loops_per_jiffy_ref = 0;
-static unsigned long cpu_khz_ref = 0;
+static unsigned int ref_freq;
+static unsigned long loops_per_jiffy_ref;
+static unsigned long cpu_khz_ref;
static int
time_cpufreq_notifier(struct notifier_block *nb, unsigned long val, void *data)
@@ -286,7 +286,7 @@ core_initcall(cpufreq_tsc);
/* clock source code */
-static unsigned long current_tsc_khz = 0;
+static unsigned long current_tsc_khz;
static cycle_t read_tsc(void)
{
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/