GNU Linux-libre 6.1.90-gnu
[releases.git] / arch / arm64 / boot / dts / qcom / pm6350.dtsi
1 // SPDX-License-Identifier: BSD-3-Clause
2 /*
3  * Copyright (c) 2021, Luca Weiss <luca@z3ntu.xyz>
4  */
5
6 #include <dt-bindings/input/input.h>
7 #include <dt-bindings/spmi/spmi.h>
8
9 &spmi_bus {
10         pmic@0 {
11                 compatible = "qcom,pm6350", "qcom,spmi-pmic";
12                 reg = <0x0 SPMI_USID>;
13                 #address-cells = <1>;
14                 #size-cells = <0>;
15
16                 pm6350_pon: pon@800 {
17                         compatible = "qcom,pm8998-pon";
18                         reg = <0x800>;
19                         mode-bootloader = <0x2>;
20                         mode-recovery = <0x1>;
21
22                         pm6350_pwrkey: pwrkey {
23                                 compatible = "qcom,pm8941-pwrkey";
24                                 interrupts = <0x0 0x8 0x0 IRQ_TYPE_EDGE_BOTH>;
25                                 debounce = <15625>;
26                                 bias-pull-up;
27                                 linux,code = <KEY_POWER>;
28                         };
29
30                         pm6350_resin: resin {
31                                 compatible = "qcom,pm8941-resin";
32                                 interrupts = <0x0 0x8 0x1 IRQ_TYPE_EDGE_BOTH>;
33                                 debounce = <15625>;
34                                 bias-pull-up;
35                                 status = "disabled";
36                         };
37                 };
38
39                 pm6350_gpios: gpios@c000 {
40                         compatible = "qcom,pm6350-gpio", "qcom,spmi-gpio";
41                         reg = <0xc000>;
42                         gpio-controller;
43                         gpio-ranges = <&pm6350_gpios 0 0 9>;
44                         #gpio-cells = <2>;
45                         interrupt-controller;
46                         #interrupt-cells = <2>;
47                 };
48         };
49
50         pmic@1 {
51                 compatible = "qcom,pm6350", "qcom,spmi-pmic";
52                 reg = <0x1 SPMI_USID>;
53                 #address-cells = <1>;
54                 #size-cells = <0>;
55         };
56 };