aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/pm24xx.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/pm24xx.c')
-rw-r--r--arch/arm/mach-omap2/pm24xx.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/arch/arm/mach-omap2/pm24xx.c b/arch/arm/mach-omap2/pm24xx.c
index facfffca9eac..2edeffc923a6 100644
--- a/arch/arm/mach-omap2/pm24xx.c
+++ b/arch/arm/mach-omap2/pm24xx.c
@@ -298,13 +298,10 @@ static void __init prcm_setup_regs(void)
298 WKUP_MOD, PM_WKEN); 298 WKUP_MOD, PM_WKEN);
299} 299}
300 300
301static int __init omap2_pm_init(void) 301int __init omap2_pm_init(void)
302{ 302{
303 u32 l; 303 u32 l;
304 304
305 if (!cpu_is_omap24xx())
306 return -ENODEV;
307
308 printk(KERN_INFO "Power Management for OMAP2 initializing\n"); 305 printk(KERN_INFO "Power Management for OMAP2 initializing\n");
309 l = omap2_prm_read_mod_reg(OCP_MOD, OMAP2_PRCM_REVISION_OFFSET); 306 l = omap2_prm_read_mod_reg(OCP_MOD, OMAP2_PRCM_REVISION_OFFSET);
310 printk(KERN_INFO "PRCM revision %d.%d\n", (l >> 4) & 0x0f, l & 0x0f); 307 printk(KERN_INFO "PRCM revision %d.%d\n", (l >> 4) & 0x0f, l & 0x0f);
@@ -370,17 +367,13 @@ static int __init omap2_pm_init(void)
370 * These routines need to be in SRAM as that's the only 367 * These routines need to be in SRAM as that's the only
371 * memory the MPU can see when it wakes up. 368 * memory the MPU can see when it wakes up.
372 */ 369 */
373 if (cpu_is_omap24xx()) { 370 omap2_sram_idle = omap_sram_push(omap24xx_idle_loop_suspend,
374 omap2_sram_idle = omap_sram_push(omap24xx_idle_loop_suspend, 371 omap24xx_idle_loop_suspend_sz);
375 omap24xx_idle_loop_suspend_sz);
376 372
377 omap2_sram_suspend = omap_sram_push(omap24xx_cpu_suspend, 373 omap2_sram_suspend = omap_sram_push(omap24xx_cpu_suspend,
378 omap24xx_cpu_suspend_sz); 374 omap24xx_cpu_suspend_sz);
379 }
380 375
381 arm_pm_idle = omap2_pm_idle; 376 arm_pm_idle = omap2_pm_idle;
382 377
383 return 0; 378 return 0;
384} 379}
385
386late_initcall(omap2_pm_init);