summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/pseries/processor_idle.c
diff options
context:
space:
mode:
authorDeepthi Dharwar2011-11-30 03:47:03 +0100
committerBenjamin Herrenschmidt2011-12-08 03:57:34 +0100
commite8bb3e00cff93ef2a0cfc09c3294aa37b4737e09 (patch)
tree3d9e72c1a6f600c90a93213a7b450afed39ea789 /arch/powerpc/platforms/pseries/processor_idle.c
parentpowerpc/cpuidle: Enable cpuidle and directly call cpuidle_idle_call() for pSe... (diff)
downloadkernel-qcow2-linux-e8bb3e00cff93ef2a0cfc09c3294aa37b4737e09.tar.gz
kernel-qcow2-linux-e8bb3e00cff93ef2a0cfc09c3294aa37b4737e09.tar.xz
kernel-qcow2-linux-e8bb3e00cff93ef2a0cfc09c3294aa37b4737e09.zip
powerpc/cpuidle: Handle power_save=off
This patch makes pseries_idle_driver not to be registered when power_save=off kernel boot option is specified. The cpuidle_disable variable used here is similar to its usage on x86. If cpuidle_disable is set then sysfs entries for cpuidle framework are not created and the required drivers are not loaded. Signed-off-by: Deepthi Dharwar <deepthi@linux.vnet.ibm.com> Signed-off-by: Trinabh Gupta <g.trinabh@gmail.com> Signed-off-by: Arun R Bharadwaj <arun.r.bharadwaj@gmail.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms/pseries/processor_idle.c')
-rw-r--r--arch/powerpc/platforms/pseries/processor_idle.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/pseries/processor_idle.c b/arch/powerpc/platforms/pseries/processor_idle.c
index f7e3e877cb69..085fd3f45ad2 100644
--- a/arch/powerpc/platforms/pseries/processor_idle.c
+++ b/arch/powerpc/platforms/pseries/processor_idle.c
@@ -269,6 +269,9 @@ static int pseries_idle_probe(void)
if (!firmware_has_feature(FW_FEATURE_SPLPAR))
return -ENODEV;
+ if (cpuidle_disable != IDLE_NO_OVERRIDE)
+ return -ENODEV;
+
if (max_idle_state == 0) {
printk(KERN_DEBUG "pseries processor idle disabled.\n");
return -EPERM;