[PATCH 12/17] omap4: pm-debug: Add wakeup timer and debug counters

STALE5629d

2 messages, 2 authors, 2011-03-04 · open the first message on its own page

[PATCH 12/17] omap4: pm-debug: Add wakeup timer and debug counters

From: Kevin Hilman <hidden>
Date: 2011-03-03 17:05:51

Santosh Shilimkar [off-list ref] writes:
quoted
-----Original Message-----
From: Kevin Hilman [mailto:khilman@ti.com]
Sent: Thursday, March 03, 2011 4:21 AM
To: Santosh Shilimkar
Cc: linux-omap@vger.kernel.org; linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 12/17] omap4: pm-debug: Add wakeup timer and
debug counters

Santosh Shilimkar [off-list ref] writes:
quoted
This patch adds configurable wakeup timer support in suspend. Also
for statistics pm counter support is added.

Signed-off-by: Santosh Shilimkar <redacted>
Reviewed-by: Kevin Hilman <redacted>
---
 arch/arm/mach-omap2/omap4-mpuss-lowpower.c |    8 ++++++++
 arch/arm/mach-omap2/pm-debug.c             |    6 ++++--
 arch/arm/mach-omap2/pm44xx.c               |    5 +++++
 3 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
b/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
quoted
index ab2e101..5e0141e 100644
--- a/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
+++ b/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
@@ -287,6 +287,10 @@ int omap4_enter_lowpower(unsigned int cpu,
unsigned int power_state)
quoted
 	if (cpu)
 		goto cpu_prepare;

+#ifdef CONFIG_PM_DEBUG
+	pwrdm_pre_transition();
+#endif
Why the #ifdef?
Because these stats updates are quite expensive
in low power code and for the production kernel
you don't need this extra penalty.
OK, then please fix this in the powerdomain code (or header.)

c.f. "#ifdefs are ugly" section of Documentation/SubmittingPatches

Kevin

[PATCH 12/17] omap4: pm-debug: Add wakeup timer and debug counters

From: Santosh Shilimkar <hidden>
Date: 2011-03-04 06:26:14

-----Original Message-----
From: Kevin Hilman [mailto:khilman@ti.com]
Sent: Thursday, March 03, 2011 10:36 PM
To: Santosh Shilimkar
Cc: linux-omap@vger.kernel.org; linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 12/17] omap4: pm-debug: Add wakeup timer and
debug counters

Santosh Shilimkar [off-list ref] writes:
quoted
quoted
-----Original Message-----
From: Kevin Hilman [mailto:khilman@ti.com]
Sent: Thursday, March 03, 2011 4:21 AM
To: Santosh Shilimkar
Cc: linux-omap@vger.kernel.org; linux-arm-
kernel@lists.infradead.org
quoted
quoted
Subject: Re: [PATCH 12/17] omap4: pm-debug: Add wakeup timer and
debug counters

Santosh Shilimkar [off-list ref] writes:
quoted
This patch adds configurable wakeup timer support in suspend.
Also
quoted
quoted
quoted
for statistics pm counter support is added.

Signed-off-by: Santosh Shilimkar <redacted>
Reviewed-by: Kevin Hilman <redacted>
---
 arch/arm/mach-omap2/omap4-mpuss-lowpower.c |    8 ++++++++
 arch/arm/mach-omap2/pm-debug.c             |    6 ++++--
 arch/arm/mach-omap2/pm44xx.c               |    5 +++++
 3 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
b/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
quoted
index ab2e101..5e0141e 100644
--- a/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
+++ b/arch/arm/mach-omap2/omap4-mpuss-lowpower.c
@@ -287,6 +287,10 @@ int omap4_enter_lowpower(unsigned int cpu,
unsigned int power_state)
quoted
 	if (cpu)
 		goto cpu_prepare;

+#ifdef CONFIG_PM_DEBUG
+	pwrdm_pre_transition();
+#endif
Why the #ifdef?
Because these stats updates are quite expensive
in low power code and for the production kernel
you don't need this extra penalty.
OK, then please fix this in the powerdomain code (or header.)
The trace framework also plan to use it so putting power
domain APIs under PM_DEBUG won't be good idea. So I will drop
the #ifdef from this code then
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help