Commit bc3ee18a authored by Chanho Min's avatar Chanho Min Committed by Catalin Marinas

arm64: init: Move of_clk_init to time_init

Clock providers should be initialized before clocksource_of_init.
If not, Clock source initialization can be fail to get the clock.
Acked-by: default avatarWill Deacon <will.deacon@arm.com>
Signed-off-by: default avatarChanho Min <chanho.min@lge.com>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
Signed-off-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
parent 8f071203
...@@ -393,7 +393,6 @@ void __init setup_arch(char **cmdline_p) ...@@ -393,7 +393,6 @@ void __init setup_arch(char **cmdline_p)
static int __init arm64_device_init(void) static int __init arm64_device_init(void)
{ {
of_clk_init(NULL);
of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
return 0; return 0;
} }
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include <linux/irq.h> #include <linux/irq.h>
#include <linux/delay.h> #include <linux/delay.h>
#include <linux/clocksource.h> #include <linux/clocksource.h>
#include <linux/clk-provider.h>
#include <clocksource/arm_arch_timer.h> #include <clocksource/arm_arch_timer.h>
...@@ -65,6 +66,7 @@ void __init time_init(void) ...@@ -65,6 +66,7 @@ void __init time_init(void)
{ {
u32 arch_timer_rate; u32 arch_timer_rate;
of_clk_init(NULL);
clocksource_of_init(); clocksource_of_init();
arch_timer_rate = arch_timer_get_rate(); arch_timer_rate = arch_timer_get_rate();
......
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