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

Commit 79850bad authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ARM: dts: msm: Add charger, QG, ADC and VOL_UP configuration for bengal"

parents 24c9abc5 8f6e5fec
Loading
Loading
Loading
Loading
+108 −0
Original line number Diff line number Diff line
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/iio/qcom,spmi-vadc.h>
#include <dt-bindings/input/input.h>

&soc {
	mtp_batterydata: qcom,battery-data {
		qcom,batt-id-range-pct = <15>;
		#include "qg-batterydata-alium-3600mah.dtsi"
	};
};

&qupv3_se4_2uart {
	status = "ok";
};

&pm6125_vadc {
	rf_pa1_therm {
		reg = <ADC_GPIO4_PU2>;
		label = "rf_pa1_therm";
		qcom,ratiometric;
		qcom,hw-settle-time = <200>;
		qcom,pre-scaling = <1 1>;
	};
};

&pm6125_adc_tm {
	io-channels = <&pm6125_vadc ADC_AMUX_THM1_PU2>,
			<&pm6125_vadc ADC_AMUX_THM2_PU2>,
			<&pm6125_vadc ADC_XO_THERM_PU2>,
			<&pm6125_vadc ADC_GPIO4_PU2>;

	rf_pa1_therm {
		reg = <ADC_GPIO4_PU2>;
		qcom,ratiometric;
		qcom,hw-settle-time = <200>;
	};
};

&thermal_zones {
	rf-pa1-therm-adc {
		polling-delay-passive = <0>;
		polling-delay = <0>;
		thermal-governor = "user_space";
		thermal-sensors = <&pm6125_adc_tm ADC_GPIO4_PU2>;
		wake-capable-sensor;
		trips {
			active-config0 {
				temperature = <125000>;
				hysteresis = <1000>;
				type = "passive";
			};
		};
	};
};

&pmi632_qg {
	qcom,battery-data = <&mtp_batterydata>;
	qcom,qg-iterm-ma = <100>;
	qcom,hold-soc-while-full;
	qcom,linearize-soc;
	qcom,qg-use-s7-ocv;
};

&pmi632_charger {
	qcom,battery-data = <&mtp_batterydata>;
	qcom,suspend-input-on-debug-batt;
	qcom,sw-jeita-enable;
	qcom,step-charging-enable;
	/* SMB1355 only */
	qcom,sec-charger-config = <2>;
	dpdm-supply = <&qusb_phy0>;
	qcom,charger-temp-max = <800>;
	qcom,smb-temp-max = <800>;
	qcom,auto-recharge-soc = <98>;
	qcom,flash-disable-soc = <10>;
	qcom,hw-die-temp-mitigation;
	qcom,hw-connector-mitigation;
	qcom,connector-internal-pull-kohm = <100>;
	qcom,float-option = <1>;
	qcom,thermal-mitigation = <3000000 2500000
			2000000 1500000 1000000 500000>;
};

&pm6125_gpios {
	key_vol_up {
		key_vol_up_default: key_vol_up_default {
			pins = "gpio5";
			function = "normal";
			input-enable;
			bias-pull-up;
			power-source = <0>;
		};
	};
};

&soc {
	gpio_keys {
		compatible = "gpio-keys";
		label = "gpio-keys";

		pinctrl-names = "default";
		pinctrl-0 = <&key_vol_up_default>;

		vol_up {
			label = "volume_up";
			gpios = <&pm6125_gpios 5 GPIO_ACTIVE_LOW>;
			linux,input-type = <1>;
			linux,code = <KEY_VOLUMEUP>;
			linux,can-disable;
			debounce-interval = <15>;
			gpio-key,wakeup;
		};
	};
};