xref: /linux/Documentation/devicetree/bindings/power/supply/maxim,max17201.yaml (revision 5c61f59824b5e46516ea5d0543ad7a8871567416)
1# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/power/supply/maxim,max17201.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Maxim MAX17201 fuel gauge
8
9maintainers:
10  - Dimitri Fedrau <dima.fedrau@gmail.com>
11
12allOf:
13  - $ref: power-supply.yaml#
14
15properties:
16  compatible:
17    oneOf:
18      - const: maxim,max17201
19      - items:
20          - enum:
21              - maxim,max17205
22          - const: maxim,max17201
23
24  reg:
25    items:
26      - description: ModelGauge m5 registers
27      - description: Nonvolatile registers
28
29  reg-names:
30    items:
31      - const: m5
32      - const: nvmem
33
34  interrupts:
35    maxItems: 1
36
37required:
38  - compatible
39  - reg
40  - reg-names
41
42unevaluatedProperties: false
43
44examples:
45  - |
46    #include <dt-bindings/interrupt-controller/irq.h>
47    i2c {
48      #address-cells = <1>;
49      #size-cells = <0>;
50
51      fuel-gauge@36 {
52        compatible = "maxim,max17201";
53        reg = <0x36>, <0xb>;
54        reg-names = "m5", "nvmem";
55        interrupt-parent = <&gpio0>;
56        interrupts = <31 IRQ_TYPE_LEVEL_LOW>;
57      };
58    };
59