aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2016-09-09 17:47:41 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2016-09-09 17:47:41 -0400
commitdaf6b9b68fca57effe3fcf74a8528f17516c420f (patch)
treebd9d1c30fc943bfdc712d89de3081384b22115f4
parentc4a6c70f93638821519047ba751b0145f7a9f90b (diff)
parent8a2a835bbcaa6af0ec659606d3eabc23ccaaab80 (diff)
Merge tag 'pm-4.8-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull power management fixes from Rafael Wysocki: "This includes a PM QoS framework fix from Tejun to prevent interrupts from being enabled unexpectedly during early boot and a cpufreq documentation fix. Specifics: - If the PM QoS framework invokes cancel_delayed_work_sync() during early boot, it will enable interrupts which is not expected at that point, so prevent it from happening (Tejun Heo) - Fix cpufreq statistic documentation to follow a recent change in behavior that forgot to update it as appropriate (Jean Delvare)" * tag 'pm-4.8-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: cpufreq-stats: Minor documentation fix PM / QoS: avoid calling cancel_delayed_work_sync() during early boot
-rw-r--r--Documentation/cpu-freq/cpufreq-stats.txt2
-rw-r--r--kernel/power/qos.c11
2 files changed, 11 insertions, 2 deletions
diff --git a/Documentation/cpu-freq/cpufreq-stats.txt b/Documentation/cpu-freq/cpufreq-stats.txt
index fc647492e940..8d9773f23550 100644
--- a/Documentation/cpu-freq/cpufreq-stats.txt
+++ b/Documentation/cpu-freq/cpufreq-stats.txt
@@ -103,7 +103,7 @@ Config Main Menu
103 Power management options (ACPI, APM) ---> 103 Power management options (ACPI, APM) --->
104 CPU Frequency scaling ---> 104 CPU Frequency scaling --->
105 [*] CPU Frequency scaling 105 [*] CPU Frequency scaling
106 <*> CPU frequency translation statistics 106 [*] CPU frequency translation statistics
107 [*] CPU frequency translation statistics details 107 [*] CPU frequency translation statistics details
108 108
109 109
diff --git a/kernel/power/qos.c b/kernel/power/qos.c
index 97b0df71303e..168ff442ebde 100644
--- a/kernel/power/qos.c
+++ b/kernel/power/qos.c
@@ -482,7 +482,16 @@ void pm_qos_update_request(struct pm_qos_request *req,
482 return; 482 return;
483 } 483 }
484 484
485 cancel_delayed_work_sync(&req->work); 485 /*
486 * This function may be called very early during boot, for example,
487 * from of_clk_init(), where irq needs to stay disabled.
488 * cancel_delayed_work_sync() assumes that irq is enabled on
489 * invocation and re-enables it on return. Avoid calling it until
490 * workqueue is initialized.
491 */
492 if (keventd_up())
493 cancel_delayed_work_sync(&req->work);
494
486 __pm_qos_update_request(req, new_value); 495 __pm_qos_update_request(req, new_value);
487} 496}
488EXPORT_SYMBOL_GPL(pm_qos_update_request); 497EXPORT_SYMBOL_GPL(pm_qos_update_request);