Commit 7f916a6f authored by Peng Fan's avatar Peng Fan Committed by Shawn Guo
Browse files

arm64: dts: imx93: add thermal support



Add tmu node and thermal-zones

Signed-off-by: default avatarPeng Fan <peng.fan@nxp.com>
Signed-off-by: default avatarShawn Guo <shawnguo@kernel.org>
parent 2b1d5d05
Loading
Loading
Loading
Loading
+53 −0
Original line number Diff line number Diff line
@@ -8,6 +8,7 @@
#include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/power/fsl,imx93-power.h>
#include <dt-bindings/thermal/thermal.h>

#include "imx93-pinfunc.h"

@@ -132,6 +133,38 @@ gic: interrupt-controller@48000000 {
		interrupt-parent = <&gic>;
	};

	thermal-zones {
		cpu-thermal {
			polling-delay-passive = <250>;
			polling-delay = <2000>;

			thermal-sensors = <&tmu 0>;

			trips {
				cpu_alert: cpu-alert {
					temperature = <80000>;
					hysteresis = <2000>;
					type = "passive";
				};

				cpu_crit: cpu-crit {
					temperature = <90000>;
					hysteresis = <2000>;
					type = "critical";
				};
			};

			cooling-maps {
				map0 {
					trip = <&cpu_alert>;
					cooling-device =
						<&A55_0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
						<&A55_1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
				};
			};
		};
	};

	soc@0 {
		compatible = "simple-bus";
		#address-cells = <1>;
@@ -343,6 +376,26 @@ anatop: anatop@44480000 {
				reg = <0x44480000 0x10000>;
			};

			tmu: tmu@44482000 {
				compatible = "fsl,qoriq-tmu";
				reg = <0x44482000 0x1000>;
				clocks = <&clk IMX93_CLK_TMC_GATE>;
				little-endian;
				fsl,tmu-range = <0x800000da 0x800000e9
						 0x80000102 0x8000012a
						 0x80000166 0x800001a7
						 0x800001b6>;
				fsl,tmu-calibration = <0x00000000 0x0000000e
						       0x00000001 0x00000029
						       0x00000002 0x00000056
						       0x00000003 0x000000a2
						       0x00000004 0x00000116
						       0x00000005 0x00000195
						       0x00000006 0x000001b2>;
				#thermal-sensor-cells = <1>;
			};


			adc1: adc@44530000 {
				compatible = "nxp,imx93-adc";
				reg = <0x44530000 0x10000>;