Commit 02bb4cb4 authored by Arnd Bergmann's avatar Arnd Bergmann
Browse files

Merge tag 'amlogic-dt' of...

Merge tag 'amlogic-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic into arm/dt

ARM: dts: amlogic updates for v5.12
- add thermal zones with cooling configuration

* tag 'amlogic-dt' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic:
  ARM: dts: meson8b: add the thermal-zones with cooling configuration
  ARM: dts: meson8: add the thermal-zones with cooling configuration
  ARM: dts: meson: add the ADC thermal sensor to meson.dtsi
  ARM: dts: meson: move iio-hwmon for the SoC temperature to meson.dtsi

Link: https://lore.kernel.org/r/7ho8h12bto.fsf@baylibre.com


Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents 638f7977 9073f694
Loading
Loading
Loading
Loading
+12 −0
Original line number Original line Diff line number Diff line
@@ -11,6 +11,11 @@ / {
	#size-cells = <1>;
	#size-cells = <1>;
	interrupt-parent = <&gic>;
	interrupt-parent = <&gic>;


	iio-hwmon {
		compatible = "iio-hwmon";
		io-channels = <&saradc 8>;
	};

	soc {
	soc {
		compatible = "simple-bus";
		compatible = "simple-bus";
		#address-cells = <1>;
		#address-cells = <1>;
@@ -293,6 +298,13 @@ efuse: nvmem@0 {
		};
		};
	};
	};


	thermal_sensor: thermal-sensor {
		compatible = "generic-adc-thermal";
		#thermal-sensor-cells = <0>;
		io-channels = <&saradc 8>;
		io-channel-names = "sensor-channel";
	};

	xtal: xtal-clk {
	xtal: xtal-clk {
		compatible = "fixed-clock";
		compatible = "fixed-clock";
		clock-frequency = <24000000>;
		clock-frequency = <24000000>;
+54 −0
Original line number Original line Diff line number Diff line
@@ -9,6 +9,7 @@
#include <dt-bindings/power/meson8-power.h>
#include <dt-bindings/power/meson8-power.h>
#include <dt-bindings/reset/amlogic,meson8b-clkc-reset.h>
#include <dt-bindings/reset/amlogic,meson8b-clkc-reset.h>
#include <dt-bindings/reset/amlogic,meson8b-reset.h>
#include <dt-bindings/reset/amlogic,meson8b-reset.h>
#include <dt-bindings/thermal/thermal.h>
#include "meson.dtsi"
#include "meson.dtsi"


/ {
/ {
@@ -28,6 +29,7 @@ cpu0: cpu@200 {
			resets = <&clkc CLKC_RESET_CPU0_SOFT_RESET>;
			resets = <&clkc CLKC_RESET_CPU0_SOFT_RESET>;
			operating-points-v2 = <&cpu_opp_table>;
			operating-points-v2 = <&cpu_opp_table>;
			clocks = <&clkc CLKID_CPUCLK>;
			clocks = <&clkc CLKID_CPUCLK>;
			#cooling-cells = <2>; /* min followed by max */
		};
		};


		cpu1: cpu@201 {
		cpu1: cpu@201 {
@@ -39,6 +41,7 @@ cpu1: cpu@201 {
			resets = <&clkc CLKC_RESET_CPU1_SOFT_RESET>;
			resets = <&clkc CLKC_RESET_CPU1_SOFT_RESET>;
			operating-points-v2 = <&cpu_opp_table>;
			operating-points-v2 = <&cpu_opp_table>;
			clocks = <&clkc CLKID_CPUCLK>;
			clocks = <&clkc CLKID_CPUCLK>;
			#cooling-cells = <2>; /* min followed by max */
		};
		};


		cpu2: cpu@202 {
		cpu2: cpu@202 {
@@ -50,6 +53,7 @@ cpu2: cpu@202 {
			resets = <&clkc CLKC_RESET_CPU2_SOFT_RESET>;
			resets = <&clkc CLKC_RESET_CPU2_SOFT_RESET>;
			operating-points-v2 = <&cpu_opp_table>;
			operating-points-v2 = <&cpu_opp_table>;
			clocks = <&clkc CLKID_CPUCLK>;
			clocks = <&clkc CLKID_CPUCLK>;
			#cooling-cells = <2>; /* min followed by max */
		};
		};


		cpu3: cpu@203 {
		cpu3: cpu@203 {
@@ -61,6 +65,7 @@ cpu3: cpu@203 {
			resets = <&clkc CLKC_RESET_CPU3_SOFT_RESET>;
			resets = <&clkc CLKC_RESET_CPU3_SOFT_RESET>;
			operating-points-v2 = <&cpu_opp_table>;
			operating-points-v2 = <&cpu_opp_table>;
			clocks = <&clkc CLKID_CPUCLK>;
			clocks = <&clkc CLKID_CPUCLK>;
			#cooling-cells = <2>; /* min followed by max */
		};
		};
	};
	};


@@ -190,6 +195,54 @@ power-firmware@4f00000 {
		};
		};
	};
	};


	thermal-zones {
		soc {
			polling-delay-passive = <250>; /* milliseconds */
			polling-delay = <1000>; /* milliseconds */
			thermal-sensors = <&thermal_sensor>;

			cooling-maps {
				map0 {
					trip = <&soc_passive>;
					cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&mali THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
				};

				map1 {
					trip = <&soc_hot>;
					cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
							 <&mali THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
				};
			};

			trips {
				soc_passive: soc-passive {
					temperature = <80000>; /* millicelsius */
					hysteresis = <2000>; /* millicelsius */
					type = "passive";
				};

				soc_hot: soc-hot {
					temperature = <90000>; /* millicelsius */
					hysteresis = <2000>; /* millicelsius */
					type = "hot";
				};

				soc_critical: soc-critical {
					temperature = <110000>; /* millicelsius */
					hysteresis = <2000>; /* millicelsius */
					type = "critical";
				};
			};
		};
	};

	mmcbus: bus@c8000000 {
	mmcbus: bus@c8000000 {
		compatible = "simple-bus";
		compatible = "simple-bus";
		reg = <0xc8000000 0x8000>;
		reg = <0xc8000000 0x8000>;
@@ -254,6 +307,7 @@ mali: gpu@c0000 {
			clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_MALI>;
			clocks = <&clkc CLKID_CLK81>, <&clkc CLKID_MALI>;
			clock-names = "bus", "core";
			clock-names = "bus", "core";
			operating-points-v2 = <&gpu_opp_table>;
			operating-points-v2 = <&gpu_opp_table>;
			#cooling-cells = <2>; /* min followed by max */
		};
		};
	};
	};
}; /* end of / */
}; /* end of / */
+0 −5
Original line number Original line Diff line number Diff line
@@ -70,11 +70,6 @@ gpio-poweroff {
		timeout-ms = <20000>;
		timeout-ms = <20000>;
	};
	};


	iio-hwmon {
		compatible = "iio-hwmon";
		io-channels = <&saradc 8>;
	};

	leds {
	leds {
		compatible = "gpio-leds";
		compatible = "gpio-leds";


+0 −5
Original line number Original line Diff line number Diff line
@@ -27,11 +27,6 @@ memory {
		reg = <0x40000000 0x40000000>;
		reg = <0x40000000 0x40000000>;
	};
	};


	iio-hwmon {
		compatible = "iio-hwmon";
		io-channels = <&saradc 8>;
	};

	vcck: regulator-vcck {
	vcck: regulator-vcck {
		compatible = "pwm-regulator";
		compatible = "pwm-regulator";


+0 −5
Original line number Original line Diff line number Diff line
@@ -85,11 +85,6 @@ tf_io: gpio-regulator-tf_io {
			  1800000 1>;
			  1800000 1>;
	};
	};


	iio-hwmon {
		compatible = "iio-hwmon";
		io-channels = <&saradc 8>;
	};

	rtc32k_xtal: rtc32k-xtal-clk {
	rtc32k_xtal: rtc32k-xtal-clk {
		/* X3 in the schematics */
		/* X3 in the schematics */
		compatible = "fixed-clock";
		compatible = "fixed-clock";
Loading