Skip to contentSkip to conversation

ARM: dts: msm: Add 8921 PMIC to ssbi bus

PATCH Superseded Stephen Boyd 1 participant 2 messages Apr 9, 2014

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 ARM: dts: msm: Add 8921 PMIC to ssbi bus

Add the PMIC and the sub-devices that are currently supported in the kernel to the DT.

---
 arch/arm/boot/dts/qcom-msm8960-cdp.dts | 16 +++++++++++++++
 arch/arm/boot/dts/qcom-msm8960.dtsi    | 37 ++++++++++++++++++++++++++++++++++
 2 files changed, 53 insertions(+)
arch/arm/boot/dts/qcom-msm8960-cdp.dts +16 -0
index a58fb88315f6..6f61c54a653e 100644
@@ -1,6 +1,22 @@
+#include <dt-bindings/input/input.h>
+
 #include "qcom-msm8960.dtsi"
 
 / {
 	model = "Qualcomm MSM8960 CDP";
 	compatible = "qcom,msm8960-cdp", "qcom,msm8960";
+
+};
+
+&pmicintc {
+	keypad at 148 {
+		linux,keymap = <
+			MATRIX_KEY(0, 0, KEY_VOLUMEUP)
+			MATRIX_KEY(0, 1, KEY_VOLUMEDOWN)
+			MATRIX_KEY(0, 2, KEY_CAMERA_FOCUS)
+			MATRIX_KEY(0, 3, KEY_CAMERA)
+			>;
+		keypad,num-rows = <1>;
+		keypad,num-columns = <5>;
+	};
 };
arch/arm/boot/dts/qcom-msm8960.dtsi +37 -0
index 997b7b94e117..fb7d3beece6d 100644
@@ -124,6 +124,43 @@
 		compatible = "qcom,ssbi";
 		reg = <0x500000 0x1000>;
 		qcom,controller-type = "pmic-arbiter";
+
+		pmicintc: pmic at 0 {
+			compatible = "qcom,pm8921";
+			interrupt-parent = <&msmgpio>;
+			interrupts = <104 8>;
+			#interrupt-cells = <2>;
+			interrupt-controller;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			pwrkey at 1c {
+				compatible = "qcom,pm8921-pwrkey";
+				reg = <0x1c>;
+				interrupt-parent = <&pmicintc>;
+				interrupts = <50 1>, <51 1>;
+				debounce = <15625>;
+				pull-up;
+			};
+
+			keypad at 148 {
+				compatible = "qcom,pm8921-keypad";
+				reg = <0x148>;
+				interrupt-parent = <&pmicintc>;
+				interrupts = <74 1>, <75 1>;
+				debounce = <15>;
+				scan-delay = <32>;
+				row-hold = <91500>;
+			};
+
+			rtc at 11d {
+				compatible = "qcom,pm8921-rtc";
+				interrupt-parent = <&pmicintc>;
+				interrupts = <39 1>;
+				reg = <0x11d>;
+				allow-set-time;
+			};
+		};
 	};
 
 	rng at 1a500000 {
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation
#1 lore raw

PATCH 2/2 ARM: dts: msm: Add 8058 PMIC to ssbi bus

Add the PMIC and the sub-devices that are currently supported in the kernel to the DT.

---
 arch/arm/boot/dts/qcom-msm8660-surf.dts | 30 +++++++++++++++++++++++
 arch/arm/boot/dts/qcom-msm8660.dtsi     | 42 +++++++++++++++++++++++++++++++++
 2 files changed, 72 insertions(+)
arch/arm/boot/dts/qcom-msm8660-surf.dts +30 -0
index 169bad90dac9..a27eedff62d3 100644
@@ -1,6 +1,36 @@
+#include <dt-bindings/input/input.h>
+
 #include "qcom-msm8660.dtsi"
 
 / {
 	model = "Qualcomm MSM8660 SURF";
 	compatible = "qcom,msm8660-surf", "qcom,msm8660";
 };
+
+&pmicintc {
+	keypad at 148 {
+		linux,keymap = <
+			MATRIX_KEY(0, 0, KEY_FN_F1)
+			MATRIX_KEY(0, 1, KEY_UP)
+			MATRIX_KEY(0, 2, KEY_LEFT)
+			MATRIX_KEY(0, 3, KEY_VOLUMEUP)
+			MATRIX_KEY(1, 0, KEY_FN_F2)
+			MATRIX_KEY(1, 1, KEY_RIGHT)
+			MATRIX_KEY(1, 2, KEY_DOWN)
+			MATRIX_KEY(1, 3, KEY_VOLUMEDOWN)
+			MATRIX_KEY(2, 3, KEY_ENTER)
+			MATRIX_KEY(4, 0, KEY_CAMERA_FOCUS)
+			MATRIX_KEY(4, 1, KEY_UP)
+			MATRIX_KEY(4, 2, KEY_LEFT)
+			MATRIX_KEY(4, 3, KEY_HOME)
+			MATRIX_KEY(4, 4, KEY_FN_F3)
+			MATRIX_KEY(5, 0, KEY_CAMERA)
+			MATRIX_KEY(5, 1, KEY_RIGHT)
+			MATRIX_KEY(5, 2, KEY_DOWN)
+			MATRIX_KEY(5, 3, KEY_BACK)
+			MATRIX_KEY(5, 4, KEY_MENU)
+			>;
+		keypad,num-rows = <6>;
+		keypad,num-columns = <5>;
+	};
+};
arch/arm/boot/dts/qcom-msm8660.dtsi +42 -0

47 lines not on this page · raw message

Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation