smp_cpus_done is too early for us... before we even do a device
inventory! Move update_cr16_clocksource into the tail end of
processor_probe() and stub it out on CONFIG_SMP=n builds.
Verified that clocksource0 is properly updated to use jiffies
on an SMP build.
Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
struct cpuinfo_parisc cpu_data[NR_CPUS] __read_mostly;
+extern int update_cr16_clocksource(void); /* from time.c */
+
/*
** PARISC CPU driver - claim "device" and initialize CPU data structures.
**
}
#endif
+ /* If we've registered more than one cpu,
+ * we'll use the jiffies clocksource since cr16
+ * is not synchronized between CPUs.
+ */
+ update_cr16_clocksource();
+
return 0;
}
void smp_cpus_done(unsigned int cpu_max)
{
- extern int update_cr16_clocksource(void);
-
- update_cr16_clocksource();
-
return;
}
return change;
}
+#else
+int update_cr16_clocksource(void)
+{
+ return 0; /* no change */
+}
#endif /*CONFIG_SMP*/
void __init start_cpu_itimer(void)