aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorRafael J. Wysocki <rjw@sisk.pl>2011-11-17 15:39:55 -0500
committerRafael J. Wysocki <rjw@sisk.pl>2011-11-17 15:39:55 -0500
commit88995e809f8a8115f30db24696c9137aad93d570 (patch)
tree4e21d1921b224155d49376bdc88ba25715bbd925 /arch
parent8b258cc8ac229aa7d5dcb7cc34cb35d9124498ac (diff)
PM / shmobile: Fix build of sh7372_pm_init() for CONFIG_PM unset
Fix build regression introduced by commit 056879d2f244001b2888cdc8cf (ARM: mach-shmobile: sh7372 A3SP no_suspend_console fix) by moving the intialization of the A3SP domain to a separate function and providing an empty definition of it for CONFIG_PM unset. Reported-and-tested-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-shmobile/pm-sh7372.c19
1 files changed, 14 insertions, 5 deletions
diff --git a/arch/arm/mach-shmobile/pm-sh7372.c b/arch/arm/mach-shmobile/pm-sh7372.c
index 1ec35ebe2376..f15f07e15856 100644
--- a/arch/arm/mach-shmobile/pm-sh7372.c
+++ b/arch/arm/mach-shmobile/pm-sh7372.c
@@ -232,11 +232,23 @@ struct sh7372_pm_domain sh7372_a3sp = {
232 .no_debug = true, 232 .no_debug = true,
233}; 233};
234 234
235static void sh7372_a3sp_init(void)
236{
237 /* serial consoles make use of SCIF hardware located in A3SP,
238 * keep such power domain on if "no_console_suspend" is set.
239 */
240 sh7372_a3sp.stay_on = !console_suspend_enabled;
241}
242
235struct sh7372_pm_domain sh7372_a3sg = { 243struct sh7372_pm_domain sh7372_a3sg = {
236 .bit_shift = 13, 244 .bit_shift = 13,
237}; 245};
238 246
239#endif /* CONFIG_PM */ 247#else /* !CONFIG_PM */
248
249static inline void sh7372_a3sp_init(void) {}
250
251#endif /* !CONFIG_PM */
240 252
241#if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE) 253#if defined(CONFIG_SUSPEND) || defined(CONFIG_CPU_IDLE)
242static int sh7372_do_idle_core_standby(unsigned long unused) 254static int sh7372_do_idle_core_standby(unsigned long unused)
@@ -474,10 +486,7 @@ void __init sh7372_pm_init(void)
474 /* do not convert A3SM, A3SP, A3SG, A4R power down into A4S */ 486 /* do not convert A3SM, A3SP, A3SG, A4R power down into A4S */
475 __raw_writel(0, PDNSEL); 487 __raw_writel(0, PDNSEL);
476 488
477 /* serial consoles make use of SCIF hardware located in A3SP, 489 sh7372_a3sp_init();
478 * keep such power domain on if "no_console_suspend" is set.
479 */
480 sh7372_a3sp.stay_on = !console_suspend_enabled;
481 490
482 sh7372_suspend_init(); 491 sh7372_suspend_init();
483 sh7372_cpuidle_init(); 492 sh7372_cpuidle_init();