linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alex Bee <knaerzche@gmail.com>
To: Heiko Stuebner <heiko@sntech.de>, Rob Herring <robh+dt@kernel.org>
Cc: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>,
	linux-rockchip@lists.infradead.org, devicetree@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Alex Bee <knaerzche@gmail.com>
Subject: [PATCH 3/4] arm64: dts: rockchip: Add cooling map / trip points for RK356x' GPU
Date: Fri, 26 Nov 2021 16:17:28 +0100	[thread overview]
Message-ID: <20211126151729.1026566-4-knaerzche@gmail.com> (raw)
In-Reply-To: <20211126151729.1026566-1-knaerzche@gmail.com>

RK356x SoCs have a second thermal sensor for the GPU:
This adds the cooling map / trip points for it to make use of it's
contribution as a cooling device.

Signed-off-by: Alex Bee <knaerzche@gmail.com>
---
 arch/arm64/boot/dts/rockchip/rk356x.dtsi | 27 ++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm64/boot/dts/rockchip/rk356x.dtsi b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
index 3b314ccd6c94..a67c279c164d 100644
--- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
@@ -960,6 +960,33 @@ gpu_thermal: gpu-thermal {
 			polling-delay = <1000>; /* milliseconds */
 
 			thermal-sensors = <&tsadc 1>;
+
+			trips {
+				gpu_threshold: gpu-threshold {
+					temperature = <70000>;
+					hysteresis = <2000>;
+					type = "passive";
+				};
+				gpu_target: gpu-target {
+					temperature = <75000>;
+					hysteresis = <2000>;
+					type = "passive";
+				};
+				gpu_crit: gpu-crit {
+					temperature = <95000>;
+					hysteresis = <2000>;
+					type = "critical";
+				};
+			};
+
+			cooling-maps {
+				map0 {
+					trip = <&gpu_target>;
+					cooling-device =
+						<&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+				};
+			};
+
 		};
 	};
 
-- 
2.30.2


  parent reply	other threads:[~2021-11-26 15:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-26 15:17 [PATCH 0/4] add GPU for RK356x SoCs Alex Bee
2021-11-26 15:17 ` [PATCH 1/4] dt-bindings: gpu: mali-bifrost: Allow up to two clocks Alex Bee
2021-12-01 23:31   ` Rob Herring
2021-11-26 15:17 ` [PATCH 2/4] arm64: dts: rockchip: Add GPU node for rk3568 Alex Bee
2021-11-26 15:17 ` Alex Bee [this message]
2021-11-26 15:17 ` [PATCH 4/4] arm64: dts: rockchip: Enable the GPU on Quartz64 Model A Alex Bee
2022-01-14 16:25   ` Piotr Oniszczuk
2022-01-14 16:42     ` Robin Murphy
2022-01-14 17:56       ` Piotr Oniszczuk
2021-11-29 12:15 ` [PATCH 0/4] add GPU for RK356x SoCs Ezequiel Garcia
2022-01-18 15:18 ` Heiko Stübner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211126151729.1026566-4-knaerzche@gmail.com \
    --to=knaerzche@gmail.com \
    --cc=devicetree@vger.kernel.org \
    --cc=ezequiel@vanguardiasur.com.ar \
    --cc=heiko@sntech.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).