From: Tony Lindgren Date: Fri, 1 Jul 2005 18:40:48 +0000 (-0700) Subject: ARM: OMAP: Sync pm.c dyntick call with mainline X-Git-Tag: v2.6.13-omap1~76 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=a29e6ebf6150bb509f24cbf01bd3a32d12522341;p=linux-2.6-omap-h63xx.git ARM: OMAP: Sync pm.c dyntick call with mainline Sync pm.c dyntick call with mainline --- diff --git a/arch/arm/mach-omap/pm.c b/arch/arm/mach-omap/pm.c index e234fde4172..61d9ec7f79f 100644 --- a/arch/arm/mach-omap/pm.c +++ b/arch/arm/mach-omap/pm.c @@ -90,10 +90,6 @@ void omap_pm_idle(void) } mask32 = omap_readl(ARM_SYSST); -#if defined(CONFIG_OMAP_32K_TIMER) && defined(CONFIG_NO_IDLE_HZ) - timer_dyn_reprogram(); -#endif - /* * Prevent the ULPD from entering low power state by setting * POWER_CTRL_REG:4 = 0 @@ -101,6 +97,13 @@ void omap_pm_idle(void) omap_writew(omap_readw(ULPD_POWER_CTRL) & ~ULPD_DEEP_SLEEP_TRANSITION_EN, ULPD_POWER_CTRL); + /* + * Since an interrupt may set up a timer, we don't want to + * reprogram the hardware timer with interrupts enabled. + * Re-enable interrupts only after returning from idle. + */ + timer_dyn_reprogram(); + if ((mask32 & DSP_IDLE) == 0) { __asm__ volatile ("mcr p15, 0, r0, c7, c0, 4"); } else