From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxime Ripard Subject: Re: [PATCH v3 25/30] ARM: dts: sun8i: h3: add thermal zone to H3 Date: Fri, 31 Aug 2018 11:14:05 +0200 Message-ID: <20180831091405.qr5daepgmx3otq7m@flea> References: <20180830154518.29507-1-embed3d@gmail.com> <20180830154518.29507-26-embed3d@gmail.com> Reply-To: maxime.ripard-LDxbnhwyfcJBDgjK7y7TUQ@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="dnpyaz3qnlascrvt" Return-path: Sender: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Content-Disposition: inline In-Reply-To: <20180830154518.29507-26-embed3d-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , To: Philipp Rossak Cc: lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org, robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, mark.rutland-5wv7dgnIgG8@public.gmane.org, wens-jdAy2FN1RRM@public.gmane.org, linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org, jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, knaack.h-Mmb7MZpHnFY@public.gmane.org, lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org, pmeerw-jW+XmwGofnusTnJN9+BGXg@public.gmane.org, eugen.hristev-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org, rdunlap-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org, vilhelm.gray-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org, clabbe.montjoie-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org, quentin.schulz-LDxbnhwyfcJBDgjK7y7TUQ@public.gmane.org, geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org, lukas-JFq808J9C/izQB+pC5nmwQ@public.gmane.org, icenowy-h8G6r0blFSE@public.gmane.org, arnd-r2nGTMty4D4@public.gmane.org, broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, arnaud.pouliquen-qxv4g6HH51o@public.gmane.org, linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-Id: devicetree@vger.kernel.org --dnpyaz3qnlascrvt Content-Type: text/plain; charset="UTF-8" Content-Disposition: inline On Thu, Aug 30, 2018 at 05:45:13PM +0200, Philipp Rossak wrote: > This patch adds the thermal zones to the H3. We have only one sensor and > that is placed in the cpu. > > Signed-off-by: Philipp Rossak > --- > arch/arm/boot/dts/sun8i-h3.dtsi | 31 +++++++++++++++++++++++++++++++ > arch/arm/boot/dts/sunxi-h3-h5.dtsi | 1 + > 2 files changed, 32 insertions(+) > > diff --git a/arch/arm/boot/dts/sun8i-h3.dtsi b/arch/arm/boot/dts/sun8i-h3.dtsi > index 5b7994cb1471..954848d5df50 100644 > --- a/arch/arm/boot/dts/sun8i-h3.dtsi > +++ b/arch/arm/boot/dts/sun8i-h3.dtsi > @@ -78,6 +78,8 @@ > clock-names = "cpu"; > operating-points-v2 = <&cpu0_opp_table>; > #cooling-cells = <2>; > + cooling-min-level = <0>; > + cooling-max-level = <15>; > }; > > cpu@1 { > @@ -102,6 +104,35 @@ > }; > }; > > + thermal-zones { > + cpu-thermal { > + /* milliseconds */ > + polling-delay-passive = <250>; > + polling-delay = <1000>; > + thermal-sensors = <&ths>; > + > + trips { > + cpu_hot_trip: cpu-warm { > + temperature = <65000>; > + hysteresis = <2000>; > + type = "passive"; > + }; > + cpu_very_hot_trip: cpu-very-hot { > + temperature = <90000>; > + hysteresis = <2000>; > + type = "critical"; > + }; > + }; Where are those trip points coming from? Maxime -- Maxime Ripard, Bootlin Embedded Linux and Kernel engineering https://bootlin.com --dnpyaz3qnlascrvt--