[PATCH] intel_idle: Do not load if user overrides idle function via idle= boot param

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Len,

I found that by review, it's compile tested only.
Could you give this a review and apply if appropriate.

Thanks,

     Thomas

----

if idle= boot param is passed, cpuidle drivers should not register
and only arch specific idle routines should get active.

Ideally cpuidle subsystem would be made aware of this.
But acpi parses sleep state tables before registering for cpuidle
which should not happen if idle= is passed.

-> Check for boot_option_idle_override in cpuidle drivers, not
cpuidle subsystem.

Compare with:
arch/x86/kernel/process.c
and
drivers/acpi/processor_idle.c

Signed-off-by: Thomas Renninger <trenn@xxxxxxx>
CC: lenb@xxxxxxxxxx
CC: linux-acpi@xxxxxxxxxxxxxxx
CC: stable@xxxxxxxxxx
CC: linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx                                                                                                                               
 
diff --git a/drivers/idle/intel_idle.c b/drivers/idle/intel_idle.c
index 41665d2..e50389b 100644
--- a/drivers/idle/intel_idle.c
+++ b/drivers/idle/intel_idle.c
@@ -410,6 +410,9 @@ static int __init intel_idle_init(void)
 {
 	int retval;
 
+	if (boot_option_idle_override)
+		return -ENODEV;
+
 	retval = intel_idle_probe();
 	if (retval)
 		return retval;
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux