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

Commit 20b85920 authored by Asha Magadi Venkateshamurthy's avatar Asha Magadi Venkateshamurthy
Browse files

ARM: dts: msm: Enable Thermistor Support for msm8905 QRD SKUB



The external thermistor is connected to MPP4. Enable support to read
this through the ADC by configuring MPP4 to AMUX8 and reading it
through the VADC pre-mux4 channel.

Change-Id: I47e53164de484b67ea0d75ad50a195257ecdcd0b
Signed-off-by: default avatarAsha Magadi Venkateshamurthy <amagad@codeaurora.org>
parent d456e616
Loading
Loading
Loading
Loading
+8 −25
Original line number Diff line number Diff line
@@ -51,33 +51,16 @@
		};

		pm8909_mpps: mpps {
			compatible = "qcom,qpnp-pin";
			spmi-dev-container;
			compatible = "qcom,spmi-mpp";
			reg = <0xa000 0x400>;
			interrupts = <0x0 0xa0 0 IRQ_TYPE_NONE>,
				<0x0 0xa1 0 IRQ_TYPE_NONE>,
				<0x0 0xa2 0 IRQ_TYPE_NONE>,
				<0x0 0xa3 0 IRQ_TYPE_NONE>;
			interrupt-names = "pm8909_mpp1", "pm8909_mpp2",
					"pm8909_mpp3", "pm8909_mpp4";
			gpio-controller;
			#gpio-cells = <2>;
			#address-cells = <1>;
			#size-cells = <1>;
			label = "pm8909-mpp";

			mpp@a000 {
				reg = <0xa000 0x100>;
				qcom,pin-num = <1>;
			};

			mpp@a100 {
				reg = <0xa100 0x100>;
				qcom,pin-num = <2>;
			};

			mpp@a200 {
				reg = <0xa200 0x100>;
				qcom,pin-num = <3>;
			};

			mpp@a300 {
				reg = <0xa300 0x100>;
				qcom,pin-num = <4>;
			};
		};

		pm8909_gpios: gpios {
+9 −7
Original line number Diff line number Diff line
@@ -197,18 +197,20 @@
};

&pm8909_mpps {
	mpp@a300 { /* MPP 4 */
		 /* CASE_THERM config */
		 qcom,mode = <4>; /* AIN input */
		 qcom,invert = <1>; /* Enable MPP */
		 qcom,ain-route = <3>; /* AMUX 8 */
		 qcom,master-en = <1>;
		 qcom,src-sel = <0>; /* Function constant */
	case_therm {
		cas_therm_default: cas_therm_default {
			pins = "mpp4";
			function = "analog";
			input-enable;
			qcom,amux-route = <3>;
		};
	};
};

&pm8909_vadc {
	#thermal-sensor-cells = <1>;
	pinctrl-names = "default";
	pinctrl-0 = <&cas_therm_default>;
	chan@30 {
		qcom,scale-function = <12>;
	};