summaryrefslogtreecommitdiff
path: root/arch/arm/mach-omap2/prm44xx.c
diff options
context:
space:
mode:
authorPaul Walmsley <paul@pwsan.com>2012-11-22 03:15:16 +0400
committerPaul Walmsley <paul@pwsan.com>2012-11-22 03:15:16 +0400
commit63a293e0005eb86c76657256737a931add8acbdc (patch)
tree121dd5100883538a32f00f24923828e5a3d42a04 /arch/arm/mach-omap2/prm44xx.c
parent558a0780b0a04862a678f7823215424b4e5501f9 (diff)
downloadlinux-63a293e0005eb86c76657256737a931add8acbdc.tar.xz
ARM: OMAP2+: PRM: initialize some PRM functions early
Some PRM functions will need to be called by the hwmod code early in kernel init. To handle this, split the PRM initialization code into early and late phases. The early init is handled via mach-omap2/io.c, while the late init is handled by subsys_initcall(). Signed-off-by: Paul Walmsley <paul@pwsan.com>
Diffstat (limited to 'arch/arm/mach-omap2/prm44xx.c')
-rw-r--r--arch/arm/mach-omap2/prm44xx.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/arch/arm/mach-omap2/prm44xx.c b/arch/arm/mach-omap2/prm44xx.c
index 6d3467af205d..9db1bd279f8e 100644
--- a/arch/arm/mach-omap2/prm44xx.c
+++ b/arch/arm/mach-omap2/prm44xx.c
@@ -615,22 +615,24 @@ static struct prm_ll_data omap44xx_prm_ll_data = {
.read_reset_sources = &omap44xx_prm_read_reset_sources,
};
-static int __init omap44xx_prm_init(void)
+int __init omap44xx_prm_init(void)
{
- int ret;
-
if (!cpu_is_omap44xx())
return 0;
- ret = prm_register(&omap44xx_prm_ll_data);
- if (ret)
- return ret;
+ return prm_register(&omap44xx_prm_ll_data);
+}
+
+static int __init omap44xx_prm_late_init(void)
+{
+ if (!cpu_is_omap44xx())
+ return 0;
omap44xx_prm_enable_io_wakeup();
return omap_prcm_register_chain_handler(&omap4_prcm_irq_setup);
}
-subsys_initcall(omap44xx_prm_init);
+subsys_initcall(omap44xx_prm_late_init);
static void __exit omap44xx_prm_exit(void)
{