]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/4.19.34/cpufreq-acpi-cpufreq-report-if-cpu-doesn-t-support-b.patch
Linux 4.19.34
[thirdparty/kernel/stable-queue.git] / releases / 4.19.34 / cpufreq-acpi-cpufreq-report-if-cpu-doesn-t-support-b.patch
CommitLineData
ba172962
SL
1From 859ec1ddd6a82520744e8c25c3b1611385a1a299 Mon Sep 17 00:00:00 2001
2From: Erwan Velu <erwanaliasr1@gmail.com>
3Date: Wed, 20 Feb 2019 11:10:17 +0100
4Subject: cpufreq: acpi-cpufreq: Report if CPU doesn't support boost
5 technologies
6
7[ Upstream commit 1222d527f314c86a3b59a522115d62facc5a7965 ]
8
9There is some rare cases where CPB (and possibly IDA) are missing on
10processors.
11
12This is the case fixed by commit f7f3dc00f612 ("x86/cpu/AMD: Fix
13erratum 1076 (CPB bit)") and following.
14
15In such context, the boost status isn't reported by
16/sys/devices/system/cpu/cpufreq/boost.
17
18This commit is about printing a message to report that the CPU
19doesn't expose the boost capabilities.
20
21This message could help debugging platforms hit by this phenomena.
22
23Signed-off-by: Erwan Velu <e.velu@criteo.com>
24[ rjw: Change the message text somewhat ]
25Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
26Signed-off-by: Sasha Levin <sashal@kernel.org>
27---
28 drivers/cpufreq/acpi-cpufreq.c | 4 +++-
29 1 file changed, 3 insertions(+), 1 deletion(-)
30
31diff --git a/drivers/cpufreq/acpi-cpufreq.c b/drivers/cpufreq/acpi-cpufreq.c
32index b61f4ec43e06..aca30f45172e 100644
33--- a/drivers/cpufreq/acpi-cpufreq.c
34+++ b/drivers/cpufreq/acpi-cpufreq.c
35@@ -911,8 +911,10 @@ static void __init acpi_cpufreq_boost_init(void)
36 {
37 int ret;
38
39- if (!(boot_cpu_has(X86_FEATURE_CPB) || boot_cpu_has(X86_FEATURE_IDA)))
40+ if (!(boot_cpu_has(X86_FEATURE_CPB) || boot_cpu_has(X86_FEATURE_IDA))) {
41+ pr_debug("Boost capabilities not present in the processor\n");
42 return;
43+ }
44
45 acpi_cpufreq_driver.set_boost = set_boost;
46 acpi_cpufreq_driver.boost_enabled = boost_state(0);
47--
482.19.1
49