OMAP3: PM: disable sys_clkreq signalling while audio is active
[pandora-kernel.git] / arch / arm / mach-omap2 / pm34xx.c
index 5722025..dabc07f 100644 (file)
@@ -503,6 +503,15 @@ out:
        local_irq_enable();
 }
 
+void omap3_pm_alow_pmic_idle(int allow)
+{
+       /* enable sys_clkreq signalling on RET */
+       omap2_prm_rmw_mod_reg_bits((OMAP3430_AUTO_OFF_MASK | OMAP3430_AUTO_RET_MASK
+               | OMAP3430_AUTO_SLEEP_MASK), allow ? OMAP3430_AUTO_RET_MASK : 0,
+               OMAP3430_GR_MOD, OMAP3_PRM_VOLTCTRL_OFFSET);
+}
+EXPORT_SYMBOL(omap3_pm_alow_pmic_idle);
+
 #ifdef CONFIG_SUSPEND
 static int omap3_pm_suspend(void)
 {
@@ -739,10 +748,7 @@ static void __init prcm_setup_regs(void)
        omap3_iva_idle();
        omap3_d2d_idle();
 
-       /* enable sys_clkreq signalling */
-       omap2_prm_rmw_mod_reg_bits((OMAP3430_AUTO_OFF_MASK | OMAP3430_AUTO_RET_MASK
-               | OMAP3430_AUTO_SLEEP_MASK), OMAP3430_AUTO_RET_MASK,
-               OMAP3430_GR_MOD, OMAP3_PRM_VOLTCTRL_OFFSET);
+       omap3_pm_alow_pmic_idle(1);
 }
 
 void omap3_pm_off_mode_enable(int enable)