diff options
author | Tero Kristo <t-kristo@ti.com> | 2014-03-04 15:43:04 (GMT) |
---|---|---|
committer | Tero Kristo <t-kristo@ti.com> | 2014-07-04 14:02:21 (GMT) |
commit | ba12c24286296159a1271eb19f2fc5c2ef59fbde (patch) | |
tree | 4282350c3d4906d60383d9ba66da141b0cd43104 /arch/arm/mach-omap2/control.c | |
parent | c2148e5930cdd2dd964e18fb7057c1e07f63c363 (diff) | |
download | linux-ba12c24286296159a1271eb19f2fc5c2ef59fbde.tar.xz |
ARM: OMAP3: control: isolate control module init to its own function
Control module related PM initializations are now moved within control
module driver. Done in preparation to isolate the code to its own driver.
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2/control.c')
-rw-r--r-- | arch/arm/mach-omap2/control.c | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/control.c b/arch/arm/mach-omap2/control.c index f432ffc..f4796c0 100644 --- a/arch/arm/mach-omap2/control.c +++ b/arch/arm/mach-omap2/control.c @@ -564,7 +564,7 @@ int omap3_ctrl_save_padconf(void) * Sets the bootmode for IVA2 to idle. This is needed by the PM code to * force disable IVA2 so that it does not prevent any low-power states. */ -void omap3_ctrl_set_iva_bootmode_idle(void) +static void __init omap3_ctrl_set_iva_bootmode_idle(void) { omap_ctrl_writel(OMAP3_IVA2_BOOTMOD_IDLE, OMAP343X_CONTROL_IVA2_BOOTMOD); @@ -576,7 +576,7 @@ void omap3_ctrl_set_iva_bootmode_idle(void) * Sets up the pads controlling the stacked modem in such way that the * device can enter idle. */ -void omap3_ctrl_setup_d2d_padconf(void) +static void __init omap3_ctrl_setup_d2d_padconf(void) { u16 mask, padconf; @@ -595,4 +595,19 @@ void omap3_ctrl_setup_d2d_padconf(void) padconf |= mask; omap_ctrl_writew(padconf, OMAP3_PADCONF_SAD2D_IDLEACK); } + +/** + * omap3_ctrl_init - does static initializations for control module + * + * Initializes system control module. This sets up the sysconfig autoidle, + * and sets up modem and iva2 so that they can be idled properly. + */ +void __init omap3_ctrl_init(void) +{ + omap_ctrl_writel(OMAP3430_AUTOIDLE_MASK, OMAP2_CONTROL_SYSCONFIG); + + omap3_ctrl_set_iva_bootmode_idle(); + + omap3_ctrl_setup_d2d_padconf(); +} #endif /* CONFIG_ARCH_OMAP3 && CONFIG_PM */ |