Commit 0dfed24c authored by David S. Miller's avatar David S. Miller

[SPARC64]: Kill up_clock_tick, use cpu_data().

parent fdf2c07b
...@@ -131,7 +131,7 @@ void __init device_scan(void) ...@@ -131,7 +131,7 @@ void __init device_scan(void)
prom_printf("No cpu nodes, cannot continue\n"); prom_printf("No cpu nodes, cannot continue\n");
prom_halt(); prom_halt();
} }
up_clock_tick = prom_getintdefault(cpu_node, cpu_data(0).clock_tick = prom_getintdefault(cpu_node,
"clock-frequency", "clock-frequency",
0); 0);
} }
......
...@@ -593,10 +593,6 @@ extern void smp_info(struct seq_file *); ...@@ -593,10 +593,6 @@ extern void smp_info(struct seq_file *);
extern void smp_bogo(struct seq_file *); extern void smp_bogo(struct seq_file *);
extern void mmu_info(struct seq_file *); extern void mmu_info(struct seq_file *);
#ifndef CONFIG_SMP
unsigned long up_clock_tick;
#endif
static int show_cpuinfo(struct seq_file *m, void *__unused) static int show_cpuinfo(struct seq_file *m, void *__unused)
{ {
seq_printf(m, seq_printf(m,
...@@ -623,7 +619,7 @@ static int show_cpuinfo(struct seq_file *m, void *__unused) ...@@ -623,7 +619,7 @@ static int show_cpuinfo(struct seq_file *m, void *__unused)
#ifndef CONFIG_SMP #ifndef CONFIG_SMP
, loops_per_jiffy/(500000/HZ), , loops_per_jiffy/(500000/HZ),
(loops_per_jiffy/(5000/HZ)) % 100, (loops_per_jiffy/(5000/HZ)) % 100,
up_clock_tick cpu_data(0).clock_tick
#endif #endif
); );
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
......
...@@ -1013,11 +1013,7 @@ unsigned long sparc64_get_clock_tick(unsigned int cpu) ...@@ -1013,11 +1013,7 @@ unsigned long sparc64_get_clock_tick(unsigned int cpu)
if (ft->clock_tick_ref) if (ft->clock_tick_ref)
return ft->clock_tick_ref; return ft->clock_tick_ref;
#ifdef CONFIG_SMP
return cpu_data(cpu).clock_tick; return cpu_data(cpu).clock_tick;
#else
return up_clock_tick;
#endif
} }
#ifdef CONFIG_CPU_FREQ #ifdef CONFIG_CPU_FREQ
...@@ -1029,7 +1025,6 @@ static int sparc64_cpufreq_notifier(struct notifier_block *nb, unsigned long val ...@@ -1029,7 +1025,6 @@ static int sparc64_cpufreq_notifier(struct notifier_block *nb, unsigned long val
unsigned int cpu = freq->cpu; unsigned int cpu = freq->cpu;
struct freq_table *ft = &per_cpu(sparc64_freq_table, cpu); struct freq_table *ft = &per_cpu(sparc64_freq_table, cpu);
#ifdef CONFIG_SMP
if (!ft->ref_freq) { if (!ft->ref_freq) {
ft->ref_freq = freq->old; ft->ref_freq = freq->old;
ft->udelay_val_ref = cpu_data(cpu).udelay_val; ft->udelay_val_ref = cpu_data(cpu).udelay_val;
...@@ -1046,18 +1041,6 @@ static int sparc64_cpufreq_notifier(struct notifier_block *nb, unsigned long val ...@@ -1046,18 +1041,6 @@ static int sparc64_cpufreq_notifier(struct notifier_block *nb, unsigned long val
ft->ref_freq, ft->ref_freq,
freq->new); freq->new);
} }
#else
/* In the non-SMP case, kernel/cpufreq.c takes care of adjusting
* loops_per_jiffy.
*/
if (!ft->ref_freq) {
ft->ref_freq = freq->old;
ft->clock_tick_ref = up_clock_tick;
}
if ((val == CPUFREQ_PRECHANGE && freq->old < freq->new) ||
(val == CPUFREQ_POSTCHANGE && freq->old > freq->new))
up_clock_tick = cpufreq_scale(ft->clock_tick_ref, ft->ref_freq, freq->new);
#endif
return 0; return 0;
} }
......
...@@ -69,10 +69,6 @@ struct pt_regs; ...@@ -69,10 +69,6 @@ struct pt_regs;
extern void timer_tick_interrupt(struct pt_regs *); extern void timer_tick_interrupt(struct pt_regs *);
#endif #endif
#ifndef CONFIG_SMP
extern unsigned long up_clock_tick;
#endif
extern unsigned long sparc64_get_clock_tick(unsigned int cpu); extern unsigned long sparc64_get_clock_tick(unsigned int cpu);
#endif /* _SPARC64_TIMER_H */ #endif /* _SPARC64_TIMER_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment