diff options
author | Magnus Damm <damm@opensource.se> | 2011-09-25 17:21:02 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2011-09-25 17:21:02 -0400 |
commit | a0089bd617adea27ebc352e1e0871649ab1dbaa6 (patch) | |
tree | 0719ce3601acf6bdd55267d02039f79c971739df /arch/arm | |
parent | cf33835c5fc528cacd4f98bc38f246022dad340d (diff) |
ARM: mach-shmobile: sh7372 sleep warning fixes
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>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-shmobile/pm-sh7372.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/sleep-sh7372.S | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/arch/arm/mach-shmobile/pm-sh7372.c b/arch/arm/mach-shmobile/pm-sh7372.c index 444f42fe1359..8e0944f96ba1 100644 --- a/arch/arm/mach-shmobile/pm-sh7372.c +++ b/arch/arm/mach-shmobile/pm-sh7372.c | |||
@@ -189,6 +189,7 @@ struct sh7372_pm_domain sh7372_a3sg = { | |||
189 | 189 | ||
190 | #endif /* CONFIG_PM */ | 190 | #endif /* CONFIG_PM */ |
191 | 191 | ||
192 | #if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE) | ||
192 | static int sh7372_do_idle_core_standby(unsigned long unused) | 193 | static int sh7372_do_idle_core_standby(unsigned long unused) |
193 | { | 194 | { |
194 | cpu_do_idle(); /* WFI when SYSTBCR == 0x10 -> Core Standby */ | 195 | cpu_do_idle(); /* WFI when SYSTBCR == 0x10 -> Core Standby */ |
@@ -209,7 +210,9 @@ static void sh7372_enter_core_standby(void) | |||
209 | /* disable reset vector translation */ | 210 | /* disable reset vector translation */ |
210 | __raw_writel(0, SBAR); | 211 | __raw_writel(0, SBAR); |
211 | } | 212 | } |
213 | #endif | ||
212 | 214 | ||
215 | #ifdef CONFIG_SUSPEND | ||
213 | static void sh7372_enter_a3sm_common(int pllc0_on) | 216 | static void sh7372_enter_a3sm_common(int pllc0_on) |
214 | { | 217 | { |
215 | /* set reset vector, translate 4k */ | 218 | /* set reset vector, translate 4k */ |
@@ -351,7 +354,7 @@ static void sh7372_setup_a3sm(unsigned long msk, unsigned long msk2) | |||
351 | __raw_writel((irqcrx_high << 16) | irqcrx_low, IRQCR3); | 354 | __raw_writel((irqcrx_high << 16) | irqcrx_low, IRQCR3); |
352 | __raw_writel((irqcry_high << 16) | irqcry_low, IRQCR4); | 355 | __raw_writel((irqcry_high << 16) | irqcry_low, IRQCR4); |
353 | } | 356 | } |
354 | 357 | #endif | |
355 | 358 | ||
356 | #ifdef CONFIG_CPU_IDLE | 359 | #ifdef CONFIG_CPU_IDLE |
357 | 360 | ||
diff --git a/arch/arm/mach-shmobile/sleep-sh7372.S b/arch/arm/mach-shmobile/sleep-sh7372.S index d365842ded47..f3ab3c5810ea 100644 --- a/arch/arm/mach-shmobile/sleep-sh7372.S +++ b/arch/arm/mach-shmobile/sleep-sh7372.S | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <asm/memory.h> | 34 | #include <asm/memory.h> |
35 | #include <asm/assembler.h> | 35 | #include <asm/assembler.h> |
36 | 36 | ||
37 | #if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE) | ||
37 | .align 12 | 38 | .align 12 |
38 | .text | 39 | .text |
39 | .global sh7372_resume_core_standby_a3sm | 40 | .global sh7372_resume_core_standby_a3sm |
@@ -91,3 +92,4 @@ sh7372_do_idle_a3sm: | |||
91 | 92 | ||
92 | kernel_flush: | 93 | kernel_flush: |
93 | .word v7_flush_dcache_all | 94 | .word v7_flush_dcache_all |
95 | #endif | ||