Skip to contentSkip to conversation

cpufreq: qcom: fix compatibility issue with old binding

PATCH Superseded Ansuel Smith 2 participants 3 messages Apr 22, 2020

Subsystems (5)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 cpufreq: qcom: fix compatibility issue with old binding

Binding has changed from operating-points-v2-kryo-cpu to operating-points-v2-qcom-cpu. Also check for old binding in driver probe.

Fixes a8811ec764f9 cpufreq: qcom: Add support for krait based socs
---
 drivers/cpufreq/qcom-cpufreq-nvmem.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/cpufreq/qcom-cpufreq-nvmem.c +4 -0
index a1b8238872a2..8a0411efc79a 100644
@@ -278,6 +278,10 @@ static int qcom_cpufreq_probe(struct platform_device *pdev)
 		return -ENOENT;
 
 	ret = of_device_is_compatible(np, "operating-points-v2-qcom-cpu");
+	if (!ret)
+		ret = of_device_is_compatible(np,
+					      "operating-points-v2-kyro-cpu");
+
 	if (!ret) {
 		of_node_put(np);
 		return -ENOENT;
Signature · 1 line
2.25.1
#1 lore raw

PATCH 2/2 dt-bindings: opp: Fix wrong binding in qcom-nvmem-cpufreq

Update binding to new generic name "operating-points-v2-qcom-cpu"

Fixes a8811ec764f9 cpufreq: qcom: Add support for krait based socs
---
 Documentation/devicetree/bindings/opp/qcom-nvmem-cpufreq.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Documentation/devicetree/bindings/opp/qcom-nvmem-cpufreq.txt +1 -1
index 64f07417ecfb..537e1774f589 100644
@@ -19,7 +19,7 @@ In 'cpu' nodes:
 
 In 'operating-points-v2' table:
 - compatible: Should be
-	- 'operating-points-v2-kryo-cpu' for apq8096, msm8996, msm8974,
+	- 'operating-points-v2-qcom-cpu' for apq8096, msm8996, msm8974,
 					     apq8064, ipq8064, msm8960 and ipq8074.
 
 Optional properties:
Signature · 1 line
2.25.1
#2 lore raw
In reply to Ansuel Smith

Hi Ansuel,

Quoted 5 lines · Ansuel Smith

Binding has changed from operating-points-v2-kryo-cpu to operating-points-v2-qcom-cpu. Also check for old binding in driver probe.

Fixes a8811ec764f9 cpufreq: qcom: Add support for krait based socs

The correct format is: Fixes: %h (\"%s\")

Quoted 10 lines
---
 drivers/cpufreq/qcom-cpufreq-nvmem.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/cpufreq/qcom-cpufreq-nvmem.c +0 -0
index a1b8238872a2..8a0411efc79a 100644

drivers/cpufreq/qcom-cpufreq-nvmem.c static int qcom_cpufreq_probe(struct platform_device *pdev) · line 283

Quoted 6 lines
drivers/cpufreq/qcom-cpufreq-nvmem.c +3 -0
@@ -278,6 +278,10 @@ static int qcom_cpufreq_probe(struct platform_device *pdev)
 		return -ENOENT;
 
 	ret = of_device_is_compatible(np, "operating-points-v2-qcom-cpu");
+	if (!ret)
+		ret = of_device_is_compatible(np,
+					      "operating-points-v2-kyro-cpu");

There is a typo in the compatible string.

Thanks,
Georgi

Quoted 5 lines
drivers/cpufreq/qcom-cpufreq-nvmem.c +1 -0
+
 	if (!ret) {
 		of_node_put(np);
 		return -ENOENT;