[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <24406e36f6facd93e798113303e22925b0a2dcc1.camel@icenowy.me>
Date: Mon, 12 Aug 2024 10:40:36 +0800
From: Icenowy Zheng <uwu@...nowy.me>
To: Dragan Simic <dsimic@...jaro.org>, linux-sunxi@...ts.linux.dev
Cc: wens@...e.org, jernej.skrabec@...il.com, samuel@...lland.org,
linux-arm-kernel@...ts.infradead.org, devicetree@...r.kernel.org,
robh@...nel.org, krzk+dt@...nel.org, conor+dt@...nel.org,
linux-kernel@...r.kernel.org, wenst@...omium.org, broonie@...nel.org
Subject: Re: [PATCH] arm64: dts: allwinner: Add GPU thermal trips to the SoC
dtsi for A64
在 2024-08-12星期一的 04:00 +0200,Dragan Simic写道:
> Add thermal trips for the two GPU thermal sensors found in the
> Allwinner A64.
> There's only one GPU OPP defined since the commit 1428f0c19f9c
> ("arm64: dts:
> allwinner: a64: Run GPU at 432 MHz"), so defining only the critical
> thermal
> trips makes sense for the A64's two GPU thermal zones.
>
> Having these critical thermal trips defined ensures that no hot spots
> develop
> inside the SoC die that exceed the maximum junction temperature.
> That might
> have been possible before, although quite unlikely, because the CPU
> and GPU
> portions of the SoC are packed closely inside the SoC, so the
> overheating GPU
> would inevitably result in the heat soaking into the CPU portion of
> the SoC,
> causing the CPU thermal sensor to return high readings and trigger
> the CPU
> critical thermal trips. However, it's better not to rely on the heat
> soak
> and have the critical GPU thermal trips properly defined instead.
>
> While there, remove a few spotted comments that are rather redundant,
> because
> it's pretty much obvious what units are used in those places.
This should be another individual patch, I think.
>
> Signed-off-by: Dragan Simic <dsimic@...jaro.org>
> ---
> arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 22 ++++++++++++++---
> --
> 1 file changed, 16 insertions(+), 6 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> index e868ca5ae753..bc5d3a2e6c98 100644
> --- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
> @@ -212,7 +212,6 @@ timer {
>
> thermal-zones {
> cpu_thermal: cpu0-thermal {
> - /* milliseconds */
The unit of a 0 isn't not so obvious I think, so I suggest to keep
this.
> polling-delay-passive = <0>;
> polling-delay = <0>;
> thermal-sensors = <&ths 0>;
> @@ -236,40 +235,51 @@ map1 {
>
> trips {
> cpu_alert0: cpu-alert0 {
> - /* milliCelsius */
> temperature = <75000>;
> hysteresis = <2000>;
> type = "passive";
> };
>
> cpu_alert1: cpu-alert1 {
> - /* milliCelsius */
> temperature = <90000>;
> hysteresis = <2000>;
> type = "hot";
> };
>
> cpu_crit: cpu-crit {
> - /* milliCelsius */
> temperature = <110000>;
> hysteresis = <2000>;
> type = "critical";
> };
> };
> };
>
> gpu0_thermal: gpu0-thermal {
> - /* milliseconds */
> polling-delay-passive = <0>;
> polling-delay = <0>;
> thermal-sensors = <&ths 1>;
> +
> + trips {
> + gpu0_crit: gpu0-crit {
> + temperature = <110000>;
> + hysteresis = <2000>;
> + type = "critical";
> + };
> + };
> };
>
> gpu1_thermal: gpu1-thermal {
> - /* milliseconds */
> polling-delay-passive = <0>;
> polling-delay = <0>;
> thermal-sensors = <&ths 2>;
> +
> + trips {
> + gpu1_crit: gpu1-crit {
> + temperature = <110000>;
> + hysteresis = <2000>;
> + type = "critical";
> + };
> + };
> };
> };
>
Powered by blists - more mailing lists