1*59604ba7SSebastian Reichel# SPDX-License-Identifier: GPL-2.0
2*59604ba7SSebastian Reichel%YAML 1.2
3*59604ba7SSebastian Reichel---
4*59604ba7SSebastian Reichel$id: "http://devicetree.org/schemas/power/supply/dlg,da9150-fuel-gauge.yaml#"
5*59604ba7SSebastian Reichel$schema: "http://devicetree.org/meta-schemas/core.yaml#"
6*59604ba7SSebastian Reichel
7*59604ba7SSebastian Reicheltitle: Dialog Semiconductor DA9150 Fuel-Gauge Power Supply bindings
8*59604ba7SSebastian Reichel
9*59604ba7SSebastian Reichelmaintainers:
10*59604ba7SSebastian Reichel  - Sebastian Reichel <sre@kernel.org>
11*59604ba7SSebastian Reichel
12*59604ba7SSebastian ReichelallOf:
13*59604ba7SSebastian Reichel  - $ref: power-supply.yaml#
14*59604ba7SSebastian Reichel
15*59604ba7SSebastian Reichelproperties:
16*59604ba7SSebastian Reichel  compatible:
17*59604ba7SSebastian Reichel    const: dlg,da9150-fuel-gauge
18*59604ba7SSebastian Reichel
19*59604ba7SSebastian Reichel  dlg,update-interval:
20*59604ba7SSebastian Reichel    $ref: /schemas/types.yaml#/definitions/uint32
21*59604ba7SSebastian Reichel    description: Interval time (milliseconds) between battery level checks.
22*59604ba7SSebastian Reichel
23*59604ba7SSebastian Reichel  dlg,warn-soc-level:
24*59604ba7SSebastian Reichel    $ref: /schemas/types.yaml#/definitions/uint8
25*59604ba7SSebastian Reichel    minimum: 1
26*59604ba7SSebastian Reichel    maximum: 100
27*59604ba7SSebastian Reichel    description: Battery discharge level (%) where warning event raised.
28*59604ba7SSebastian Reichel
29*59604ba7SSebastian Reichel  dlg,crit-soc-level:
30*59604ba7SSebastian Reichel    $ref: /schemas/types.yaml#/definitions/uint8
31*59604ba7SSebastian Reichel    minimum: 1
32*59604ba7SSebastian Reichel    maximum: 100
33*59604ba7SSebastian Reichel    description: |
34*59604ba7SSebastian Reichel      Battery discharge level (%) where critical event raised.
35*59604ba7SSebastian Reichel      This value should be lower than the warning level.
36*59604ba7SSebastian Reichel
37*59604ba7SSebastian Reichelrequired:
38*59604ba7SSebastian Reichel  - compatible
39*59604ba7SSebastian Reichel
40*59604ba7SSebastian ReicheladditionalProperties: false
41*59604ba7SSebastian Reichel
42*59604ba7SSebastian Reichelexamples:
43*59604ba7SSebastian Reichel  - |
44*59604ba7SSebastian Reichel    pmic {
45*59604ba7SSebastian Reichel      battery {
46*59604ba7SSebastian Reichel        compatible = "dlg,da9150-fuel-gauge";
47*59604ba7SSebastian Reichel        dlg,update-interval = <10000>;
48*59604ba7SSebastian Reichel        dlg,warn-soc-level = /bits/ 8 <15>;
49*59604ba7SSebastian Reichel        dlg,crit-soc-level = /bits/ 8 <5>;
50*59604ba7SSebastian Reichel      };
51*59604ba7SSebastian Reichel    };
52