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>
#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 */
/* 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 */
__raw_writel((irqcrx_high << 16) | irqcrx_low, IRQCR3);
__raw_writel((irqcry_high << 16) | irqcry_low, IRQCR4);
}
-
+#endif
#ifdef CONFIG_CPU_IDLE
#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
kernel_flush:
.word v7_flush_dcache_all
+#endif