Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7eb39309 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ARM: dts: msm: Add BCL sensors and default thermal zone rules for PM6150L"

parents 166363b6 627fdcd0
Loading
Loading
Loading
Loading
+144 −0
Original line number Diff line number Diff line
@@ -66,6 +66,9 @@
			qcom,pmic-revid = <&pm6150_revid>;
			qcom,auto-recharge-soc = <98>;

			qcom,thermal-mitigation = <4200000 3500000 3000000
					2500000 2000000 1500000 1000000 500000>;

			qcom,chgr@1000 {
				reg = <0x1000 0x100>;
				interrupts =
@@ -225,6 +228,27 @@
			};
		};

		pm6150_bcl: bcl@1d00 {
			compatible = "qcom,bcl-v5";
			reg = <0x1d00 0x100>;
			interrupts = <0x0 0x1d 0x0 IRQ_TYPE_NONE>,
					<0x0 0x1d 0x1 IRQ_TYPE_NONE>,
					<0x0 0x1d 0x0 IRQ_TYPE_NONE>,
					<0x0 0x1d 0x1 IRQ_TYPE_NONE>,
					<0x0 0x1d 0x2 IRQ_TYPE_NONE>;
			interrupt-names = "bcl-ibat-lvl0",
						"bcl-ibat-lvl1",
						"bcl-vbat-lvl0",
						"bcl-vbat-lvl1",
						"bcl-vbat-lvl2";
			#thermal-sensor-cells = <1>;
		};

		bcl_soc:bcl-soc {
			compatible = "qcom,msm-bcl-soc";
			#thermal-sensor-cells = <0>;
		};

		pm6150_tz: qcom,temp-alarm@2400 {
			compatible = "qcom,spmi-temp-alarm";
			reg = <0x2400 0x100>;
@@ -295,3 +319,123 @@
	};
};

&thermal_zones {
	pm6150_temp_alarm: pm6150-tz {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "step_wise";
		thermal-sensors = <&pm6150_tz>;

		trips {
			pm6150_trip0: trip0 {
				temperature = <95000>;
				hysteresis = <0>;
				type = "passive";
			};
			pm6150_trip1: trip1 {
				temperature = <115000>;
				hysteresis = <0>;
				type = "passive";
			};
			trip2 {
				temperature = <145000>;
				hysteresis = <0>;
				type = "passive";
			};
		};
	};

	pm6150-ibat-lvl0 {
		polling-delay-passive = <100>;
		polling-delay = <0>;
		thermal-governor = "step_wise";
		thermal-sensors = <&pm6150_bcl 0>;

		trips {
			ibat_lvl0:ibat-lvl0 {
				temperature = <5500>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150-ibat-lvl1 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "step_wise";
		thermal-sensors = <&pm6150_bcl 1>;

		trips {
			ibat_lvl1:ibat-lvl1 {
				temperature = <6000>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150-vbat-lvl0 {
		polling-delay-passive = <100>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150_bcl 2>;
		tracks-low;

		trips {
			vbat_lvl0: vbat-lvl0 {
				temperature = <3000>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150-vbat-lvl1 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150_bcl 3>;
		tracks-low;

		trips {
			vbat_lvl1:vbat-lvl1 {
				temperature = <2800>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150-vbat-lvl2 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150_bcl 4>;
		tracks-low;

		trips {
			vbat_lvl2:vbat-lvl2 {
				temperature = <2600>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	soc {
		polling-delay-passive = <100>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&bcl_soc>;
		tracks-low;

		trips {
			soc_trip:soc-trip {
				temperature = <10>;
				hysteresis = <0>;
				type = "passive";
			};
		};
	};
};
+87 −0
Original line number Diff line number Diff line
@@ -39,6 +39,18 @@
			qcom,temperature-threshold-set = <1>;
		};

		pm6150l_bcl: bcl@3d00 {
			compatible = "qcom,bcl-v5";
			reg = <0x3d00 0x100>;
			interrupts = <0x4 0x3d 0x0 IRQ_TYPE_NONE>,
					<0x4 0x3d 0x1 IRQ_TYPE_NONE>,
					<0x4 0x3d 0x2 IRQ_TYPE_NONE>;
			interrupt-names = "bcl-vbat-lvl0",
						"bcl-vbat-lvl1",
						"bcl-vbat-lvl2";
			#thermal-sensor-cells = <1>;
		};

		pm6150l_clkdiv: clock-controller@5b00 {
			compatible = "qcom,spmi-clkdiv";
			reg = <0x5b00 0x100>;
@@ -267,3 +279,78 @@
		};
	};
};

&thermal_zones {
	pm6150l_temp_alarm: pm6150l-tz {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "step_wise";
		thermal-sensors = <&pm6150l_tz>;

		trips {
			pm6150l_trip0: trip0 {
				temperature = <95000>;
				hysteresis = <0>;
				type = "passive";
			};
			pm6150l_trip1: trip1 {
				temperature = <115000>;
				hysteresis = <0>;
				type = "passive";
			};
			trip2 {
				temperature = <145000>;
				hysteresis = <0>;
				type = "passive";
			};
		};
	};

	pm6150l-vph-lvl0 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150l_bcl 2>;
		tracks-low;

		trips {
			vph_lvl0: vph-lvl0 {
				temperature = <3000>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150l-vph-lvl1 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150l_bcl 3>;
		tracks-low;

		trips {
			vph_lvl1:vph-lvl1 {
				temperature = <2750>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};

	pm6150l-vph-lvl2 {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "low_limits_cap";
		thermal-sensors = <&pm6150l_bcl 4>;
		tracks-low;

		trips {
			vph_lvl2:vph-lvl2 {
				temperature = <2500>;
				hysteresis = <200>;
				type = "passive";
			};
		};
	};
};
+2 −0
Original line number Diff line number Diff line
@@ -10,6 +10,8 @@
 * GNU General Public License for more details.
 */

#include "sm6150-thermal-overlay.dtsi"

&soc {
};

+2 −0
Original line number Diff line number Diff line
@@ -10,6 +10,8 @@
 * GNU General Public License for more details.
 */

#include "sm6150-thermal-overlay.dtsi"

&soc {
};

+2 −0
Original line number Diff line number Diff line
@@ -10,5 +10,7 @@
 * GNU General Public License for more details.
 */

#include "sm6150-thermal-overlay.dtsi"

&soc {
};
Loading