Most DT ARM machs require common clock providers initialized before timers.
Currently, arch/arm machs use .init_time to call clk_of_init right before
clocksource_of_init. This prevents to remove that hook and use the default
hook instead. clk_of_init now checks for multiple calls to it, so add
the call to ARM arch time_init by default.

Signed-off-by: Sebastian Hesselbarth <[email protected]>
---
Cc: Mike Turquette <[email protected]> 
Cc: Russell King <[email protected]>
Cc: Arnd Bergmann <[email protected]>
Cc: [email protected] 
Cc: [email protected] 
---
 arch/arm/kernel/time.c |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/kernel/time.c b/arch/arm/kernel/time.c
index 98aee32..94b51b8 100644
--- a/arch/arm/kernel/time.c
+++ b/arch/arm/kernel/time.c
@@ -22,6 +22,7 @@
 #include <linux/errno.h>
 #include <linux/profile.h>
 #include <linux/timer.h>
+#include <linux/clk-provider.h>
 #include <linux/clocksource.h>
 #include <linux/irq.h>
 #include <linux/sched_clock.h>
@@ -116,6 +117,9 @@ int __init register_persistent_clock(clock_access_fn 
read_boot,
 
 void __init time_init(void)
 {
+       /* initalize common clocks before timers */
+       of_clk_init(NULL);
+
        if (machine_desc->init_time)
                machine_desc->init_time();
        else
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to