From 8a1daa8f893b05f519b0a247a6ebd5d5a881aee5 Mon Sep 17 00:00:00 2001 From: Hema HK Date: Fri, 24 Sep 2010 10:23:19 -0600 Subject: [PATCH] --- yaml --- r: 216900 b: refs/heads/master c: 78f26e872f77b6312273216de1a8f836c6f2e143 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/arm/mach-omap2/omap_hwmod.c | 17 +++++++++++------ 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/[refs] b/[refs] index dab22ab6bd85..69046fe8a6a8 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ff173d45525701d65d394cb8687e71845bfb34dc +refs/heads/master: 78f26e872f77b6312273216de1a8f836c6f2e143 diff --git a/trunk/arch/arm/mach-omap2/omap_hwmod.c b/trunk/arch/arm/mach-omap2/omap_hwmod.c index c3a5889d8add..955861acc0c4 100644 --- a/trunk/arch/arm/mach-omap2/omap_hwmod.c +++ b/trunk/arch/arm/mach-omap2/omap_hwmod.c @@ -777,12 +777,6 @@ static void _enable_sysc(struct omap_hwmod *oh) _set_master_standbymode(oh, idlemode, &v); } - if (sf & SYSC_HAS_AUTOIDLE) { - idlemode = (oh->flags & HWMOD_NO_OCP_AUTOIDLE) ? - 0 : 1; - _set_module_autoidle(oh, idlemode, &v); - } - /* * XXX The clock framework should handle this, by * calling into this code. But this must wait until the @@ -797,6 +791,17 @@ static void _enable_sysc(struct omap_hwmod *oh) /* If slave is in SMARTIDLE, also enable wakeup */ if ((sf & SYSC_HAS_SIDLEMODE) && !(oh->flags & HWMOD_SWSUP_SIDLE)) _enable_wakeup(oh); + + /* + * Set the autoidle bit only after setting the smartidle bit + * Setting this will not have any impact on the other modules. + */ + if (sf & SYSC_HAS_AUTOIDLE) { + idlemode = (oh->flags & HWMOD_NO_OCP_AUTOIDLE) ? + 0 : 1; + _set_module_autoidle(oh, idlemode, &v); + _write_sysconfig(v, oh); + } } /**