Re: [linux-pm] [PATCH 11/18] cpuidle: stop using pm_idle
From: Trinabh Gupta
Date: Mon Apr 25 2011 - 06:41:36 EST
On 04/02/2011 11:52 AM, Len Brown wrote:
From: Len Brown<len.brown@xxxxxxxxx>
pm_idle does not scale as an idle handler registration mechanism.
Don't use it for cpuidle. Instead, call cpuidle directly, and
allow architectures to use pm_idle as an arch-specific default
if they need it. ie.
cpu_idle()
...
if(cpuidle_call_idle())
pm_idle();
Hi Len,
This doesn't compile right now for ARM. The patch below
(on top of your series) is required to compile on arm, sh
Thanks,
-Trinabh
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
index d7ee0d4..1a347f4 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -197,7 +197,7 @@ void cpu_idle(void)
cpu_relax();
} else {
stop_critical_timings();
- if (cpuidle_call_idle())
+ if (cpuidle_idle_call())
pm_idle();
start_critical_timings();
/*
diff --git a/arch/sh/kernel/idle.c b/arch/sh/kernel/idle.c
index 9c7099e..1db1968 100644
--- a/arch/sh/kernel/idle.c
+++ b/arch/sh/kernel/idle.c
@@ -101,7 +101,7 @@ void cpu_idle(void)
local_irq_disable();
/* Don't trace irqs off for idle */
stop_critical_timings();
- if (cpuidle_call_idle())
+ if (cpuidle_idle_call())
pm_idle();
/*
* Sanity check to ensure that pm_idle() returns
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/