arm64: dts: qcom: pm8916: Add resin node
authorStephan Gerhold <stephan@gerhold.net>
Mon, 20 Jul 2020 08:54:02 +0000 (10:54 +0200)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Tue, 15 Sep 2020 04:49:38 +0000 (04:49 +0000)
Right now we define the entire pm8916 resin node separately in
the board-specific device tree part, including the interrupt that
belongs to PM8916.

As a feature of the PMIC it should be declared in pm8916.dtsi,
disabled by default. Like all other optional components it can then
by enabled and configured in the board-specific device tree part.

Signed-off-by: Stephan Gerhold <stephan@gerhold.net>
Link: https://lore.kernel.org/r/20200720085406.6716-7-stephan@gerhold.net
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
arch/arm64/boot/dts/qcom/apq8016-sbc.dtsi
arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi
arch/arm64/boot/dts/qcom/pm8916.dtsi

index 5552773f633e885af94db29c5ce23120ebf5868c..3e42ba9cca94516795e8948d207ad6b209f122bb 100644 (file)
        status = "okay";
 };
 
+&pm8916_resin {
+       status = "okay";
+       linux,code = <KEY_VOLUMEDOWN>;
+};
+
 &pronto {
        status = "okay";
 };
        };
 };
 
-&spmi_bus {
-       pm8916_0: pm8916@0 {
-               pon@800 {
-                       resin {
-                               compatible = "qcom,pm8941-resin";
-                               interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
-                               debounce = <15625>;
-                               bias-pull-up;
-                               linux,code = <KEY_VOLUMEDOWN>;
-                       };
-               };
-       };
-};
-
 &usb {
        status = "okay";
        extcon = <&usb_id>, <&usb_id>;
index 68d89a8acbcfcf531be05735e154cd8ee3293dbd..90ce0f96eda472e968ca6aaf11c56d261b5c5810 100644 (file)
        pinctrl-1 = <&blsp1_uart2_sleep>;
 };
 
+&pm8916_resin {
+       status = "okay";
+       linux,code = <KEY_VOLUMEDOWN>;
+};
+
 &pronto {
        status = "okay";
 };
        non-removable;
 };
 
-&spmi_bus {
-       pm8916@0 {
-               pon@800 {
-                       volume-down {
-                               compatible = "qcom,pm8941-resin";
-                               interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
-                               bias-pull-up;
-                               linux,code = <KEY_VOLUMEDOWN>;
-                       };
-               };
-       };
-};
-
 &usb {
        status = "okay";
        dr_mode = "peripheral";
index 89b1418eeeb4342ba7949f213aaa9e9b8bb561a3..c6eb0b0cd84981af7e87bd2f9c97ea636ec9a972 100644 (file)
        vddio-supply = <&pm8916_l6>;
 };
 
+&pm8916_resin {
+       status = "okay";
+       linux,code = <KEY_VOLUMEDOWN>;
+};
+
 &pronto {
        status = "okay";
 };
        cd-gpios = <&msmgpio 38 GPIO_ACTIVE_LOW>;
 };
 
-&spmi_bus {
-       pm8916@0 {
-               pon@800 {
-                       volume-down {
-                               compatible = "qcom,pm8941-resin";
-                               interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
-                               bias-pull-up;
-                               linux,code = <KEY_VOLUMEDOWN>;
-                       };
-               };
-       };
-};
-
 &usb {
        status = "okay";
        extcon = <&muic>, <&muic>;
index 0bcdf047110791c664331ec16038cdacaa5f1920..c3f62090aff723644c6557c75a4d1bfd49dda577 100644 (file)
                                linux,code = <KEY_POWER>;
                        };
 
+                       pm8916_resin: resin {
+                               compatible = "qcom,pm8941-resin";
+                               interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
+                               debounce = <15625>;
+                               bias-pull-up;
+                               status = "disabled";
+                       };
+
                        watchdog {
                                compatible = "qcom,pm8916-wdt";
                                interrupts = <0x0 0x8 6 IRQ_TYPE_EDGE_RISING>;