arm64: dts: qcom: purwa: deduplicate thermal sensors with Hamoa

Hamoa and Purwa have pretty close thermal zones definitions. The major
difference is that several zones are absent (because of the lack of the
CPU cluster) and several zones use tsens2 instead of tsens3.

Instead of completely duplicating thermal zones for Purwa, reuse themal
zones from Hamoa, patching them where required.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Reviewed-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260320-purwa-drop-thermals-v1-1-2c9fe046cd02@oss.qualcomm.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
This commit is contained in:
Dmitry Baryshkov 2026-03-20 04:33:15 +02:00 committed by Bjorn Andersson
parent eb5fa758f7
commit 2c098c2bae
2 changed files with 80 additions and 576 deletions

View File

@ -9316,7 +9316,7 @@ aoss0-critical {
};
};
cpu2-0-top-thermal {
thermal_cpu2_0_top: cpu2-0-top-thermal {
thermal-sensors = <&tsens2 1>;
trips {
@ -9328,7 +9328,7 @@ cpu-critical {
};
};
cpu2-0-btm-thermal {
thermal_cpu2_0_btm: cpu2-0-btm-thermal {
thermal-sensors = <&tsens2 2>;
trips {
@ -9340,7 +9340,7 @@ cpu-critical {
};
};
cpu2-1-top-thermal {
thermal_cpu2_1_top: cpu2-1-top-thermal {
thermal-sensors = <&tsens2 3>;
trips {
@ -9352,7 +9352,7 @@ cpu-critical {
};
};
cpu2-1-btm-thermal {
thermal_cpu2_1_btm: cpu2-1-btm-thermal {
thermal-sensors = <&tsens2 4>;
trips {
@ -9364,7 +9364,7 @@ cpu-critical {
};
};
cpu2-2-top-thermal {
thermal_cpu2_2_top: cpu2-2-top-thermal {
thermal-sensors = <&tsens2 5>;
trips {
@ -9376,7 +9376,7 @@ cpu-critical {
};
};
cpu2-2-btm-thermal {
thermal_cpu2_2_btm: cpu2-2-btm-thermal {
thermal-sensors = <&tsens2 6>;
trips {
@ -9388,7 +9388,7 @@ cpu-critical {
};
};
cpu2-3-top-thermal {
thermal_cpu2_3_top: cpu2-3-top-thermal {
thermal-sensors = <&tsens2 7>;
trips {
@ -9400,7 +9400,7 @@ cpu-critical {
};
};
cpu2-3-btm-thermal {
thermal_cpu2_3_btm: cpu2-3-btm-thermal {
thermal-sensors = <&tsens2 8>;
trips {
@ -9412,7 +9412,7 @@ cpu-critical {
};
};
cpuss2-top-thermal {
thermal_cpuss2_top: cpuss2-top-thermal {
thermal-sensors = <&tsens2 9>;
trips {
@ -9424,7 +9424,7 @@ cpuss2-critical {
};
};
cpuss2-btm-thermal {
thermal_cpuss2_btm: cpuss2-btm-thermal {
thermal-sensors = <&tsens2 10>;
trips {
@ -9436,7 +9436,7 @@ cpuss2-critical {
};
};
aoss3-thermal {
thermal_aoss3: aoss3-thermal {
thermal-sensors = <&tsens3 0>;
trips {
@ -9454,7 +9454,7 @@ aoss0-critical {
};
};
nsp0-thermal {
thermal_nsp0: nsp0-thermal {
thermal-sensors = <&tsens3 1>;
trips {
@ -9472,7 +9472,7 @@ nsp0-critical {
};
};
nsp1-thermal {
thermal_nsp1: nsp1-thermal {
thermal-sensors = <&tsens3 2>;
trips {
@ -9490,7 +9490,7 @@ nsp1-critical {
};
};
nsp2-thermal {
thermal_nsp2: nsp2-thermal {
thermal-sensors = <&tsens3 3>;
trips {
@ -9508,7 +9508,7 @@ nsp2-critical {
};
};
nsp3-thermal {
thermal_nsp3: nsp3-thermal {
thermal-sensors = <&tsens3 4>;
trips {
@ -9526,7 +9526,7 @@ nsp3-critical {
};
};
gpuss-0-thermal {
thermal_gpuss_0: gpuss-0-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 5>;
@ -9553,7 +9553,7 @@ gpu-critical {
};
};
gpuss-1-thermal {
thermal_gpuss_1: gpuss-1-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 6>;
@ -9580,7 +9580,7 @@ gpu-critical {
};
};
gpuss-2-thermal {
thermal_gpuss_2: gpuss-2-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 7>;
@ -9607,7 +9607,7 @@ gpu-critical {
};
};
gpuss-3-thermal {
thermal_gpuss_3: gpuss-3-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 8>;
@ -9634,7 +9634,7 @@ gpu-critical {
};
};
gpuss-4-thermal {
thermal_gpuss_4: gpuss-4-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 9>;
@ -9661,7 +9661,7 @@ gpu-critical {
};
};
gpuss-5-thermal {
thermal_gpuss_5: gpuss-5-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 10>;
@ -9688,7 +9688,7 @@ gpu-critical {
};
};
gpuss-6-thermal {
thermal_gpuss_6: gpuss-6-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 11>;
@ -9715,7 +9715,7 @@ gpu-critical {
};
};
gpuss-7-thermal {
thermal_gpuss_7: gpuss-7-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens3 12>;
@ -9742,7 +9742,7 @@ gpu-critical {
};
};
camera0-thermal {
thermal_camera0: camera0-thermal {
thermal-sensors = <&tsens3 13>;
trips {
@ -9760,7 +9760,7 @@ camera0-critical {
};
};
camera1-thermal {
thermal_camera1: camera1-thermal {
thermal-sensors = <&tsens3 14>;
trips {

View File

@ -20,7 +20,21 @@
/delete-node/ &gpu_opp_table;
/delete-node/ &gpu_speed_bin;
/delete-node/ &pcie3_phy;
/delete-node/ &thermal_zones;
/delete-node/ &thermal_aoss3;
/delete-node/ &thermal_cpu2_0_btm;
/delete-node/ &thermal_cpu2_0_top;
/delete-node/ &thermal_cpu2_1_btm;
/delete-node/ &thermal_cpu2_1_top;
/delete-node/ &thermal_cpu2_2_btm;
/delete-node/ &thermal_cpu2_2_top;
/delete-node/ &thermal_cpu2_3_btm;
/delete-node/ &thermal_cpu2_3_top;
/delete-node/ &thermal_cpuss2_btm;
/delete-node/ &thermal_cpuss2_top;
/delete-node/ &thermal_gpuss_4;
/delete-node/ &thermal_gpuss_5;
/delete-node/ &thermal_gpuss_6;
/delete-node/ &thermal_gpuss_7;
&gcc {
compatible = "qcom,x1p42100-gcc", "qcom,x1e80100-gcc";
@ -198,557 +212,47 @@ pcie3_phy: phy@1bd4000 {
};
};
&thermal_camera0 {
thermal-sensors = <&tsens2 9>;
};
&thermal_camera1 {
thermal-sensors = <&tsens2 10>;
};
&thermal_gpuss_0 {
thermal-sensors = <&tsens2 5>;
};
&thermal_gpuss_1 {
thermal-sensors = <&tsens2 6>;
};
&thermal_gpuss_2 {
thermal-sensors = <&tsens2 7>;
};
&thermal_gpuss_3 {
thermal-sensors = <&tsens2 8>;
};
&thermal_nsp0 {
thermal-sensors = <&tsens2 1>;
};
&thermal_nsp1 {
thermal-sensors = <&tsens2 2>;
};
&thermal_nsp2 {
thermal-sensors = <&tsens2 3>;
};
&thermal_nsp3 {
thermal-sensors = <&tsens2 4>;
};
/* While physically present, this controller is left unconfigured and unused */
&tsens3 {
status = "disabled";
};
/ {
thermal-zones {
aoss0-thermal {
thermal-sensors = <&tsens0 0>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-0-top-thermal {
thermal-sensors = <&tsens0 1>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-0-btm-thermal {
thermal-sensors = <&tsens0 2>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-1-top-thermal {
thermal-sensors = <&tsens0 3>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-1-btm-thermal {
thermal-sensors = <&tsens0 4>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-2-top-thermal {
thermal-sensors = <&tsens0 5>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-2-btm-thermal {
thermal-sensors = <&tsens0 6>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-3-top-thermal {
thermal-sensors = <&tsens0 7>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu0-3-btm-thermal {
thermal-sensors = <&tsens0 8>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpuss0-top-thermal {
thermal-sensors = <&tsens0 9>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpuss0-btm-thermal {
thermal-sensors = <&tsens0 10>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
mem-thermal {
thermal-sensors = <&tsens0 11>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <0>;
type = "critical";
};
};
};
video-thermal {
thermal-sensors = <&tsens0 12>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
aoss1-thermal {
thermal-sensors = <&tsens1 0>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-0-top-thermal {
thermal-sensors = <&tsens1 1>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-0-btm-thermal {
thermal-sensors = <&tsens1 2>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-1-top-thermal {
thermal-sensors = <&tsens1 3>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-1-btm-thermal {
thermal-sensors = <&tsens1 4>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-2-top-thermal {
thermal-sensors = <&tsens1 5>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-2-btm-thermal {
thermal-sensors = <&tsens1 6>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-3-top-thermal {
thermal-sensors = <&tsens1 7>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpu1-3-btm-thermal {
thermal-sensors = <&tsens1 8>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpuss1-top-thermal {
thermal-sensors = <&tsens1 9>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
cpuss1-btm-thermal {
thermal-sensors = <&tsens1 10>;
trips {
trip-point0 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
aoss2-thermal {
thermal-sensors = <&tsens2 0>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
nsp0-thermal {
thermal-sensors = <&tsens2 1>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
nsp1-thermal {
thermal-sensors = <&tsens2 2>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
nsp2-thermal {
thermal-sensors = <&tsens2 3>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
nsp3-thermal {
thermal-sensors = <&tsens2 4>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
gpuss-0-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens2 5>;
cooling-maps {
map0 {
trip = <&gpuss0_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
gpuss0_alert0: trip-point0 {
temperature = <95000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
gpuss-1-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens2 6>;
cooling-maps {
map0 {
trip = <&gpuss1_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
gpuss1_alert0: trip-point0 {
temperature = <95000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
gpuss-2-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens2 7>;
cooling-maps {
map0 {
trip = <&gpuss2_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
gpuss2_alert0: trip-point0 {
temperature = <95000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
gpuss-3-thermal {
polling-delay-passive = <200>;
thermal-sensors = <&tsens2 8>;
cooling-maps {
map0 {
trip = <&gpuss3_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
gpuss3_alert0: trip-point0 {
temperature = <95000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
camera0-thermal {
thermal-sensors = <&tsens2 9>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
camera1-thermal {
thermal-sensors = <&tsens2 10>;
trips {
trip-point0 {
temperature = <90000>;
hysteresis = <2000>;
type = "hot";
};
trip-point1 {
temperature = <115000>;
hysteresis = <1000>;
type = "critical";
};
};
};
};
};