xref: /freebsd/sys/contrib/device-tree/Bindings/power/reset/qcom,pon.yaml (revision b97ee269eae3cbaf35c18f51a459aea581c2a7dc)
1# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/power/reset/qcom,pon.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Qualcomm PON Device
8
9maintainers:
10  - Vinod Koul <vkoul@kernel.org>
11
12description: |
13  The Power On device for Qualcomm PM8xxx is MFD supporting pwrkey
14  and resin along with the Android reboot-mode.
15
16  This DT node has pwrkey and resin as sub nodes.
17
18allOf:
19  - $ref: reboot-mode.yaml#
20
21properties:
22  compatible:
23    enum:
24      - qcom,pm8916-pon
25      - qcom,pms405-pon
26      - qcom,pm8998-pon
27
28  reg:
29    maxItems: 1
30
31  pwrkey:
32    type: object
33    $ref: /schemas/input/qcom,pm8941-pwrkey.yaml#
34
35  resin:
36    type: object
37    $ref: /schemas/input/qcom,pm8941-pwrkey.yaml#
38
39  watchdog:
40    type: object
41    $ref: /schemas/watchdog/qcom,pm8916-wdt.yaml
42
43required:
44  - compatible
45  - reg
46
47unevaluatedProperties: false
48
49examples:
50  - |
51   #include <dt-bindings/interrupt-controller/irq.h>
52   #include <dt-bindings/input/linux-event-codes.h>
53   #include <dt-bindings/spmi/spmi.h>
54   spmi_bus: spmi@c440000 {
55     reg = <0x0c440000 0x1100>;
56     #address-cells = <2>;
57     #size-cells = <0>;
58     pmk8350: pmic@0 {
59       reg = <0x0 SPMI_USID>;
60       #address-cells = <1>;
61       #size-cells = <0>;
62       pmk8350_pon: pon_hlos@1300 {
63         reg = <0x1300>;
64         compatible = "qcom,pm8998-pon";
65
66         pwrkey {
67            compatible = "qcom,pm8941-pwrkey";
68            interrupts = < 0x0 0x8 0 IRQ_TYPE_EDGE_BOTH >;
69            debounce = <15625>;
70            bias-pull-up;
71            linux,code = <KEY_POWER>;
72         };
73
74         resin {
75            compatible = "qcom,pm8941-resin";
76            interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
77            debounce = <15625>;
78            bias-pull-up;
79            linux,code = <KEY_VOLUMEDOWN>;
80         };
81       };
82     };
83   };
84...
85