All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: shmobile: r8a7740: Cleanup PM Kconfig usage
@ 2014-09-04  3:39 Magnus Damm
  2014-09-04  4:12 ` Simon Horman
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: Magnus Damm @ 2014-09-04  3:39 UTC (permalink / raw)
  To: linux-sh

From: Magnus Damm <damm+renesas@opensource.se>

Simplify the r8a7740 PM code by using CONFIG_PM_RMOBILE instead
of having a complex #if expression embedded in the C code.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Built on top of renesas-devel-20140904-v3.17-rc3

 arch/arm/mach-shmobile/pm-r8a7740.c |    6 ++++--
 arch/arm/mach-shmobile/r8a7740.h    |    7 +------
 2 files changed, 5 insertions(+), 8 deletions(-)

--- 0001/arch/arm/mach-shmobile/pm-r8a7740.c
+++ work/arch/arm/mach-shmobile/pm-r8a7740.c	2014-09-04 12:29:12.000000000 +0900
@@ -13,7 +13,7 @@
 #include "common.h"
 #include "pm-rmobile.h"
 
-#if defined(CONFIG_PM) && !defined(CONFIG_ARCH_MULTIPLATFORM)
+#ifdef CONFIG_PM_RMOBILE
 static int r8a7740_pd_a4s_suspend(void)
 {
 	/*
@@ -58,7 +58,9 @@ void __init r8a7740_init_pm_domains(void
 	rmobile_init_domains(r8a7740_pm_domains, ARRAY_SIZE(r8a7740_pm_domains));
 	pm_genpd_add_subdomain_names("A4S", "A3SP");
 }
-#endif /* CONFIG_PM && !CONFIG_ARCH_MULTIPLATFORM */
+#else
+void r8a7740_init_pm_domains(void) {}
+#endif
 
 #ifdef CONFIG_SUSPEND
 static int r8a7740_enter_suspend(suspend_state_t suspend_state)
--- 0001/arch/arm/mach-shmobile/r8a7740.h
+++ work/arch/arm/mach-shmobile/r8a7740.h	2014-09-04 12:29:12.000000000 +0900
@@ -52,11 +52,6 @@ extern void r8a7740_add_standard_devices
 extern void r8a7740_clock_init(u8 md_ck);
 extern void r8a7740_pinmux_init(void);
 extern void r8a7740_pm_init(void);
-
-#if defined(CONFIG_PM) && !defined(CONFIG_ARCH_MULTIPLATFORM)
-extern void __init r8a7740_init_pm_domains(void);
-#else
-static inline void r8a7740_init_pm_domains(void) {}
-#endif /* CONFIG_PM && !CONFIG_ARCH_MULTIPLATFORM */
+extern void r8a7740_init_pm_domains(void);
 
 #endif /* __ASM_R8A7740_H__ */

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2014-09-30  8:11 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-04  3:39 [PATCH] ARM: shmobile: r8a7740: Cleanup PM Kconfig usage Magnus Damm
2014-09-04  4:12 ` Simon Horman
2014-09-04  4:17 ` Magnus Damm
2014-09-04  4:25 ` Simon Horman
2014-09-04  4:29 ` Simon Horman
2014-09-04  6:31 ` Geert Uytterhoeven
2014-09-24  0:54 ` Simon Horman
2014-09-30  4:25 ` Simon Horman
2014-09-30  7:12 ` Geert Uytterhoeven
2014-09-30  8:11 ` Simon Horman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.