ARM: mach-shmobile: sh7372 sleep warning fixes
authorMagnus Damm <damm@opensource.se>
Sun, 25 Sep 2011 21:21:02 +0000 (23:21 +0200)
committerRafael J. Wysocki <rjw@sisk.pl>
Sun, 25 Sep 2011 21:21:02 +0000 (23:21 +0200)
Update the sh7372 sleep code to build parts of the
code only when SUSPEND and/or CPU_IDLE are set.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
arch/arm/mach-shmobile/pm-sh7372.c
arch/arm/mach-shmobile/sleep-sh7372.S

index 444f42fe13597e369f4d07b463e45afc0d1e29f4..8e0944f96ba139c610eb76de4c4a506309f8f75c 100644 (file)
@@ -189,6 +189,7 @@ struct sh7372_pm_domain sh7372_a3sg = {
 
 #endif /* CONFIG_PM */
 
+#if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE)
 static int sh7372_do_idle_core_standby(unsigned long unused)
 {
        cpu_do_idle(); /* WFI when SYSTBCR == 0x10 -> Core Standby */
@@ -209,7 +210,9 @@ static void sh7372_enter_core_standby(void)
         /* disable reset vector translation */
        __raw_writel(0, SBAR);
 }
+#endif
 
+#ifdef CONFIG_SUSPEND
 static void sh7372_enter_a3sm_common(int pllc0_on)
 {
        /* set reset vector, translate 4k */
@@ -351,7 +354,7 @@ static void sh7372_setup_a3sm(unsigned long msk, unsigned long msk2)
        __raw_writel((irqcrx_high << 16) | irqcrx_low, IRQCR3);
        __raw_writel((irqcry_high << 16) | irqcry_low, IRQCR4);
 }
-
+#endif
 
 #ifdef CONFIG_CPU_IDLE
 
index d365842ded47b71a4d905edcd61b2f5e78389fff..f3ab3c5810ea859fe33e6a0508f94096b4e74d40 100644 (file)
@@ -34,6 +34,7 @@
 #include <asm/memory.h>
 #include <asm/assembler.h>
 
+#if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE)
        .align  12
        .text
        .global sh7372_resume_core_standby_a3sm
@@ -91,3 +92,4 @@ sh7372_do_idle_a3sm:
 
 kernel_flush:
        .word v7_flush_dcache_all
+#endif
This page took 0.02805 seconds and 5 git commands to generate.