arm64: dts: qcom: sm8650: Throttle the GPU when overheating

Add an 85C passive trip point to ensure the thermal framework takes
sufficient action to prevent reaching junction temperature and a
110C critical point to help avoid hw damage.

Also, register the GPU as a cooling device and hook it up to the
right thermal zones.

Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Link: https://lore.kernel.org/r/20240510-topic-gpus_are_cool_now-v1-12-ababc269a438@linaro.org
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
This commit is contained in:
Konrad Dybcio 2024-05-10 14:58:41 +02:00 committed by Bjorn Andersson
parent ed979c039a
commit 497624ed55

View File

@ -2632,6 +2632,7 @@
operating-points-v2 = <&gpu_opp_table>;
qcom,gmu = <&gmu>;
#cooling-cells = <2>;
status = "disabled";
@ -6028,16 +6029,29 @@
thermal-sensors = <&tsens2 1>;
cooling-maps {
map0 {
trip = <&gpu0_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu0_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss0-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6048,16 +6062,29 @@
thermal-sensors = <&tsens2 2>;
cooling-maps {
map0 {
trip = <&gpu1_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu1_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss1-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6068,16 +6095,29 @@
thermal-sensors = <&tsens2 3>;
cooling-maps {
map0 {
trip = <&gpu2_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu2_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss2-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6088,16 +6128,29 @@
thermal-sensors = <&tsens2 4>;
cooling-maps {
map0 {
trip = <&gpu3_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu3_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss3-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6108,16 +6161,29 @@
thermal-sensors = <&tsens2 5>;
cooling-maps {
map0 {
trip = <&gpu4_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu4_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss4-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6128,16 +6194,29 @@
thermal-sensors = <&tsens2 6>;
cooling-maps {
map0 {
trip = <&gpu5_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu5_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss5-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6148,16 +6227,29 @@
thermal-sensors = <&tsens2 7>;
cooling-maps {
map0 {
trip = <&gpu6_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu6_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss6-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};
@ -6168,16 +6260,29 @@
thermal-sensors = <&tsens2 8>;
cooling-maps {
map0 {
trip = <&gpu7_alert0>;
cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
};
};
trips {
trip-point0 {
gpu7_alert0: trip-point0 {
temperature = <85000>;
hysteresis = <1000>;
type = "passive";
};
trip-point1 {
temperature = <90000>;
hysteresis = <2000>;
hysteresis = <1000>;
type = "hot";
};
gpuss7-critical {
trip-point2 {
temperature = <110000>;
hysteresis = <0>;
hysteresis = <1000>;
type = "critical";
};
};