diff mbox series

[2/8] arm64: dts: qcom: pmi8994: Add SMBCHG

Message ID 20220808073459.396278-3-y.oudjana@protonmail.com (mailing list archive)
State Changes Requested
Headers show
Series power: supply: Add driver for Qualcomm SMBCHG | expand

Commit Message

Yassine Oudjana Aug. 8, 2022, 7:34 a.m. UTC
From: Yassine Oudjana <y.oudjana@protonmail.com>

Add a node for the switch-mode battery charger available on
this PMIC.

Signed-off-by: Yassine Oudjana <y.oudjana@protonmail.com>
---
 arch/arm64/boot/dts/qcom/pmi8994.dtsi | 72 +++++++++++++++++++++++++++
 1 file changed, 72 insertions(+)
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/qcom/pmi8994.dtsi b/arch/arm64/boot/dts/qcom/pmi8994.dtsi
index 84c44912ec93..3e9db97c9805 100644
--- a/arch/arm64/boot/dts/qcom/pmi8994.dtsi
+++ b/arch/arm64/boot/dts/qcom/pmi8994.dtsi
@@ -10,6 +10,78 @@  pmic@2 {
 		#address-cells = <1>;
 		#size-cells = <0>;
 
+		pmi8994_smbchg: charger@1000 {
+			compatible = "qcom,pmi8994-smbchg";
+			reg = <0x1000>;
+
+			interrupts = <0x2 0x10 0x0 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x1 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x2 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x3 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x4 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x5 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x10 0x6 IRQ_TYPE_EDGE_RISING>,
+				     <0x2 0x10 0x7 IRQ_TYPE_EDGE_RISING>,
+				     <0x2 0x12 0x0 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x1 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x2 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x3 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x4 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x5 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x6 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x12 0x7 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x13 0x0 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x13 0x1 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x13 0x2 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x13 0x3 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x13 0x4 IRQ_TYPE_EDGE_RISING>,
+				     <0x2 0x13 0x5 IRQ_TYPE_EDGE_RISING>,
+				     <0x2 0x13 0x6 IRQ_TYPE_EDGE_FALLING>,
+				     <0x2 0x14 0x0 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x14 0x1 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x0 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x1 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x2 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x3 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x4 IRQ_TYPE_EDGE_BOTH>,
+				     <0x2 0x16 0x5 IRQ_TYPE_EDGE_BOTH>;
+			interrupt-names = "chg-error",
+					  "chg-inhibit",
+					  "chg-prechg-sft",
+					  "chg-complete-chg-sft",
+					  "chg-p2f-thr",
+					  "chg-rechg-thr",
+					  "chg-taper-thr",
+					  "chg-tcc-thr",
+					  "batt-hot",
+					  "batt-warm",
+					  "batt-cold",
+					  "batt-cool",
+					  "batt-ov",
+					  "batt-low",
+					  "batt-missing",
+					  "batt-term-missing",
+					  "usbin-uv",
+					  "usbin-ov",
+					  "usbin-src-det",
+					  "otg-fail",
+					  "otg-oc",
+					  "aicl-done",
+					  "usbid-change",
+					  "dcin-uv",
+					  "dcin-ov",
+					  "power-ok",
+					  "temp-shutdown",
+					  "wdog-timeout",
+					  "flash-fail",
+					  "otst2",
+					  "otst3";
+
+			status = "disabled";
+
+			chg_otg: otg-vbus { };
+		};
+
 		pmi8994_gpios: gpios@c000 {
 			compatible = "qcom,pmi8994-gpio", "qcom,spmi-gpio";
 			reg = <0xc000>;