]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
arm64: dts: qcom: sm7225-fairphone-fp4: Add PMK8003 thermals
authorLuca Weiss <luca.weiss@fairphone.com>
Fri, 5 Jul 2024 12:40:09 +0000 (14:40 +0200)
committerBjorn Andersson <andersson@kernel.org>
Sat, 6 Jul 2024 18:02:57 +0000 (13:02 -0500)
Configure the thermals for the XO_THERM thermistor connected to the
PMK8003 (which is called PMK8350 in software).

The ADC configuration for PMK8350_ADC7_AMUX_THM1_100K_PU has already
been added in the past.

The trip points can really only be considered as placeholders, more
configuration with cooling etc. can be added later.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
Link: https://lore.kernel.org/r/20240705-fp4-thermals-v2-1-a4870a8d084f@fairphone.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
arch/arm64/boot/dts/qcom/sm7225-fairphone-fp4.dts

index 4e67bb80a0267d3a77545194b35b06907d87a458..e263010c348c12aa298499c989829c6d6dc7af99 100644 (file)
                                };
                        };
                };
+
+               xo-thermal {
+                       thermal-sensors = <&pmk8350_adc_tm 0>;
+
+                       trips {
+                               active-config0 {
+                                       temperature = <125000>;
+                                       hysteresis = <1000>;
+                                       type = "passive";
+                               };
+                       };
+               };
        };
 };
 
        status = "okay";
 };
 
+&pmk8350_adc_tm {
+       status = "okay";
+
+       xo-therm@0 {
+               reg = <0>;
+               io-channels = <&pmk8350_vadc PMK8350_ADC7_AMUX_THM1_100K_PU>;
+               qcom,hw-settle-time-us = <200>;
+               qcom,ratiometric;
+       };
+};
+
 &pmk8350_rtc {
        status = "okay";
 };