aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2
diff options
context:
space:
mode:
authorNishanth Menon <nm@ti.com>2013-10-16 11:39:02 -0400
committerTony Lindgren <tony@atomide.com>2013-10-22 11:09:50 -0400
commit765e7a067eebf372687048ba0242e27f43cf0d71 (patch)
treed90e8633cbc9e9faccc4f4ca1052e38c758669a6 /arch/arm/mach-omap2
parent92d51856d7405fa55bcf3d6f20d7e97e0bf2656c (diff)
ARM: OMAP2+: add missing lateinit hook for calling pm late init
AM335x, AM43xx, OMAP5 and DRA7 have missing late init hook. Introduce SoC specific hook with a call to OMAP2+ generic lateinit hook. This allows the generic late initializations such as cpufreq hooks to be active. Based on out-of-tree patches that need to be introduced in mainline, this introduction allows us to provide the foundation for further SoC specific features as they are developed. Cc: Benoit Cousson <bcousson@baylibre.com> Cc: Kevin Hilman <khilman@deeprootsystems.com> Cc: Paul Walmsley <paul@pwsan.com> Cc: Tony Lindgren <tony@atomide.com> Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r--arch/arm/mach-omap2/board-generic.c4
-rw-r--r--arch/arm/mach-omap2/common.h4
-rw-r--r--arch/arm/mach-omap2/io.c20
3 files changed, 28 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c
index 3896b12b0006..19f1652e94cf 100644
--- a/arch/arm/mach-omap2/board-generic.c
+++ b/arch/arm/mach-omap2/board-generic.c
@@ -146,6 +146,7 @@ DT_MACHINE_START(AM33XX_DT, "Generic AM33XX (Flattened Device Tree)")
146 .init_irq = omap_intc_of_init, 146 .init_irq = omap_intc_of_init,
147 .handle_irq = omap3_intc_handle_irq, 147 .handle_irq = omap3_intc_handle_irq,
148 .init_machine = omap_generic_init, 148 .init_machine = omap_generic_init,
149 .init_late = am33xx_init_late,
149 .init_time = omap3_gptimer_timer_init, 150 .init_time = omap3_gptimer_timer_init,
150 .dt_compat = am33xx_boards_compat, 151 .dt_compat = am33xx_boards_compat,
151 .restart = am33xx_restart, 152 .restart = am33xx_restart,
@@ -185,6 +186,7 @@ DT_MACHINE_START(OMAP5_DT, "Generic OMAP5 (Flattened Device Tree)")
185 .init_early = omap5_init_early, 186 .init_early = omap5_init_early,
186 .init_irq = omap_gic_of_init, 187 .init_irq = omap_gic_of_init,
187 .init_machine = omap_generic_init, 188 .init_machine = omap_generic_init,
189 .init_late = omap5_init_late,
188 .init_time = omap5_realtime_timer_init, 190 .init_time = omap5_realtime_timer_init,
189 .dt_compat = omap5_boards_compat, 191 .dt_compat = omap5_boards_compat,
190 .restart = omap44xx_restart, 192 .restart = omap44xx_restart,
@@ -200,6 +202,7 @@ static const char *am43_boards_compat[] __initdata = {
200DT_MACHINE_START(AM43_DT, "Generic AM43 (Flattened Device Tree)") 202DT_MACHINE_START(AM43_DT, "Generic AM43 (Flattened Device Tree)")
201 .map_io = am33xx_map_io, 203 .map_io = am33xx_map_io,
202 .init_early = am43xx_init_early, 204 .init_early = am43xx_init_early,
205 .init_late = am43xx_init_late,
203 .init_irq = omap_gic_of_init, 206 .init_irq = omap_gic_of_init,
204 .init_machine = omap_generic_init, 207 .init_machine = omap_generic_init,
205 .init_time = omap3_sync32k_timer_init, 208 .init_time = omap3_sync32k_timer_init,
@@ -218,6 +221,7 @@ DT_MACHINE_START(DRA7XX_DT, "Generic DRA7XX (Flattened Device Tree)")
218 .smp = smp_ops(omap4_smp_ops), 221 .smp = smp_ops(omap4_smp_ops),
219 .map_io = omap5_map_io, 222 .map_io = omap5_map_io,
220 .init_early = dra7xx_init_early, 223 .init_early = dra7xx_init_early,
224 .init_late = dra7xx_init_late,
221 .init_irq = omap_gic_of_init, 225 .init_irq = omap_gic_of_init,
222 .init_machine = omap_generic_init, 226 .init_machine = omap_generic_init,
223 .init_time = omap5_realtime_timer_init, 227 .init_time = omap5_realtime_timer_init,
diff --git a/arch/arm/mach-omap2/common.h b/arch/arm/mach-omap2/common.h
index c6aebf0b42d8..f7644febee81 100644
--- a/arch/arm/mach-omap2/common.h
+++ b/arch/arm/mach-omap2/common.h
@@ -98,6 +98,7 @@ void am35xx_init_early(void);
98void ti81xx_init_early(void); 98void ti81xx_init_early(void);
99void am33xx_init_early(void); 99void am33xx_init_early(void);
100void am43xx_init_early(void); 100void am43xx_init_early(void);
101void am43xx_init_late(void);
101void omap4430_init_early(void); 102void omap4430_init_early(void);
102void omap5_init_early(void); 103void omap5_init_early(void);
103void omap3_init_late(void); /* Do not use this one */ 104void omap3_init_late(void); /* Do not use this one */
@@ -109,8 +110,11 @@ void omap35xx_init_late(void);
109void omap3630_init_late(void); 110void omap3630_init_late(void);
110void am35xx_init_late(void); 111void am35xx_init_late(void);
111void ti81xx_init_late(void); 112void ti81xx_init_late(void);
113void am33xx_init_late(void);
114void omap5_init_late(void);
112int omap2_common_pm_late_init(void); 115int omap2_common_pm_late_init(void);
113void dra7xx_init_early(void); 116void dra7xx_init_early(void);
117void dra7xx_init_late(void);
114 118
115#ifdef CONFIG_SOC_BUS 119#ifdef CONFIG_SOC_BUS
116void omap_soc_device_init(void); 120void omap_soc_device_init(void);
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c
index ff2113ce4014..a2cbb44582e4 100644
--- a/arch/arm/mach-omap2/io.c
+++ b/arch/arm/mach-omap2/io.c
@@ -583,6 +583,11 @@ void __init am33xx_init_early(void)
583 omap_hwmod_init_postsetup(); 583 omap_hwmod_init_postsetup();
584 omap_clk_init = am33xx_clk_init; 584 omap_clk_init = am33xx_clk_init;
585} 585}
586
587void __init am33xx_init_late(void)
588{
589 omap_common_late_init();
590}
586#endif 591#endif
587 592
588#ifdef CONFIG_SOC_AM43XX 593#ifdef CONFIG_SOC_AM43XX
@@ -596,6 +601,11 @@ void __init am43xx_init_early(void)
596 omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM43XX_PRCM_BASE), NULL); 601 omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM43XX_PRCM_BASE), NULL);
597 omap3xxx_check_revision(); 602 omap3xxx_check_revision();
598} 603}
604
605void __init am43xx_init_late(void)
606{
607 omap_common_late_init();
608}
599#endif 609#endif
600 610
601#ifdef CONFIG_ARCH_OMAP4 611#ifdef CONFIG_ARCH_OMAP4
@@ -651,6 +661,11 @@ void __init omap5_init_early(void)
651 omap54xx_hwmod_init(); 661 omap54xx_hwmod_init();
652 omap_hwmod_init_postsetup(); 662 omap_hwmod_init_postsetup();
653} 663}
664
665void __init omap5_init_late(void)
666{
667 omap_common_late_init();
668}
654#endif 669#endif
655 670
656#ifdef CONFIG_SOC_DRA7XX 671#ifdef CONFIG_SOC_DRA7XX
@@ -671,6 +686,11 @@ void __init dra7xx_init_early(void)
671 dra7xx_hwmod_init(); 686 dra7xx_hwmod_init();
672 omap_hwmod_init_postsetup(); 687 omap_hwmod_init_postsetup();
673} 688}
689
690void __init dra7xx_init_late(void)
691{
692 omap_common_late_init();
693}
674#endif 694#endif
675 695
676 696