xref: /linux/Documentation/devicetree/bindings/rtc/abracon,abx80x.yaml (revision 79790b6818e96c58fe2bffee1b418c16e64e7b80)
1626e2b54SJosua Mayer# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2626e2b54SJosua Mayer%YAML 1.2
3626e2b54SJosua Mayer---
4626e2b54SJosua Mayer$id: http://devicetree.org/schemas/rtc/abracon,abx80x.yaml#
5626e2b54SJosua Mayer$schema: http://devicetree.org/meta-schemas/core.yaml#
6626e2b54SJosua Mayer
7626e2b54SJosua Mayertitle: Abracon ABX80X I2C ultra low power RTC/Alarm chip
8626e2b54SJosua Mayer
9626e2b54SJosua Mayermaintainers:
10626e2b54SJosua Mayer  - linux-rtc@vger.kernel.org
11626e2b54SJosua Mayer
12626e2b54SJosua Mayerproperties:
13626e2b54SJosua Mayer  compatible:
14626e2b54SJosua Mayer    description:
15626e2b54SJosua Mayer      The wildcard 'abracon,abx80x' may be used to support a mix
16626e2b54SJosua Mayer      of different abracon rtc`s. In this case the driver
17626e2b54SJosua Mayer      must perform auto-detection from ID register.
18626e2b54SJosua Mayer    enum:
19626e2b54SJosua Mayer      - abracon,abx80x
20626e2b54SJosua Mayer      - abracon,ab0801
21626e2b54SJosua Mayer      - abracon,ab0803
22626e2b54SJosua Mayer      - abracon,ab0804
23626e2b54SJosua Mayer      - abracon,ab0805
24626e2b54SJosua Mayer      - abracon,ab1801
25626e2b54SJosua Mayer      - abracon,ab1803
26626e2b54SJosua Mayer      - abracon,ab1804
27626e2b54SJosua Mayer      - abracon,ab1805
28626e2b54SJosua Mayer      - microcrystal,rv1805
29626e2b54SJosua Mayer
30626e2b54SJosua Mayer  reg:
31626e2b54SJosua Mayer    maxItems: 1
32626e2b54SJosua Mayer
33626e2b54SJosua Mayer  interrupts:
34626e2b54SJosua Mayer    maxItems: 1
35626e2b54SJosua Mayer
36626e2b54SJosua Mayer  abracon,tc-diode:
37626e2b54SJosua Mayer    description:
38626e2b54SJosua Mayer      Trickle-charge diode type.
39626e2b54SJosua Mayer      Required to enable charging backup battery.
40626e2b54SJosua Mayer
41626e2b54SJosua Mayer      Supported are 'standard' diodes with a 0.6V drop
42626e2b54SJosua Mayer      and 'schottky' diodes with a 0.3V drop.
43626e2b54SJosua Mayer    $ref: /schemas/types.yaml#/definitions/string
44626e2b54SJosua Mayer    enum:
45626e2b54SJosua Mayer      - standard
46626e2b54SJosua Mayer      - schottky
47626e2b54SJosua Mayer
48626e2b54SJosua Mayer  abracon,tc-resistor:
49626e2b54SJosua Mayer    description:
50626e2b54SJosua Mayer      Trickle-charge resistor value in kOhm.
51626e2b54SJosua Mayer      Required to enable charging backup battery.
52626e2b54SJosua Mayer    $ref: /schemas/types.yaml#/definitions/uint32
53626e2b54SJosua Mayer    enum: [0, 3, 6, 11]
54626e2b54SJosua Mayer
55*32a6be08SLaurent PinchartdependentRequired:
56*32a6be08SLaurent Pinchart  abracon,tc-diode: ["abracon,tc-resistor"]
57*32a6be08SLaurent Pinchart  abracon,tc-resistor: ["abracon,tc-diode"]
58*32a6be08SLaurent Pinchart
59626e2b54SJosua Mayerrequired:
60626e2b54SJosua Mayer  - compatible
61626e2b54SJosua Mayer  - reg
62626e2b54SJosua Mayer
63*32a6be08SLaurent PinchartallOf:
64*32a6be08SLaurent Pinchart  - $ref: rtc.yaml#
65*32a6be08SLaurent Pinchart  - if:
66*32a6be08SLaurent Pinchart      properties:
67*32a6be08SLaurent Pinchart        compatible:
68*32a6be08SLaurent Pinchart          not:
69*32a6be08SLaurent Pinchart            contains:
70*32a6be08SLaurent Pinchart              enum:
71*32a6be08SLaurent Pinchart                - abracon,abx80x
72*32a6be08SLaurent Pinchart                - abracon,ab0804
73*32a6be08SLaurent Pinchart                - abracon,ab1804
74*32a6be08SLaurent Pinchart                - abracon,ab0805
75*32a6be08SLaurent Pinchart                - abracon,ab1805
76*32a6be08SLaurent Pinchart    then:
77*32a6be08SLaurent Pinchart      properties:
78*32a6be08SLaurent Pinchart        abracon,tc-diode: false
79*32a6be08SLaurent Pinchart        abracon,tc-resistor: false
80*32a6be08SLaurent Pinchart
81626e2b54SJosua MayerunevaluatedProperties: false
82626e2b54SJosua Mayer
83626e2b54SJosua Mayerexamples:
84626e2b54SJosua Mayer  - |
85626e2b54SJosua Mayer    #include <dt-bindings/interrupt-controller/irq.h>
86626e2b54SJosua Mayer
87626e2b54SJosua Mayer    i2c {
88626e2b54SJosua Mayer        #address-cells = <1>;
89626e2b54SJosua Mayer        #size-cells = <0>;
90626e2b54SJosua Mayer
91626e2b54SJosua Mayer        rtc@69 {
92626e2b54SJosua Mayer            compatible = "abracon,abx80x";
93626e2b54SJosua Mayer            reg = <0x69>;
94626e2b54SJosua Mayer            abracon,tc-diode = "schottky";
95626e2b54SJosua Mayer            abracon,tc-resistor = <3>;
96626e2b54SJosua Mayer            interrupts = <44 IRQ_TYPE_EDGE_FALLING>;
97626e2b54SJosua Mayer        };
98626e2b54SJosua Mayer    };
99