summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/leds/maxim,max77693.yaml
blob: e27f57bb52ae8bf0a432b6aacd66fec9e7eb6b88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/leds/maxim,max77693.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Maxim MAX77693 MicroUSB and Companion Power Management IC LEDs

maintainers:
  - Krzysztof Kozlowski <krzk@kernel.org>

description: |
  This is a part of device tree bindings for Maxim MAX77693 MicroUSB Integrated
  Circuit (MUIC).

  There are two LED outputs available - FLED1 and FLED2. Each of them can
  control a separate LED or they can be connected together to double the
  maximum current for a single connected LED. One LED is represented by one
  child node.

  See also Documentation/devicetree/bindings/mfd/maxim,max77693.yaml for
  additional information and example.

properties:
  compatible:
    const: maxim,max77693-led

  maxim,boost-mode:
    description:
      In boost mode the device can produce up to 1.2A of total current on both
      outputs. The maximum current on each output is reduced to 625mA then. If
      not enabled explicitly, boost setting defaults to LEDS_BOOST_FIXED in
      case both current sources are used.
      See LEDS_BOOST_* in include/dt-bindings/leds/common.h.
    $ref: /schemas/types.yaml#/definitions/uint32
    enum: [0, 1, 2]

  maxim,boost-mvout:
    description: |
      Output voltage of the boost module in millivolts.
      Valid values: 3300 - 5500, step by 25 (rounded down)
    $ref: /schemas/types.yaml#/definitions/uint32
    minimum: 3300
    maximum: 5500
    default: 3300

  maxim,mvsys-min:
    description: |
      Low input voltage level in millivolts. Flash is not fired if chip
      estimates that system voltage could drop below this level due to flash
      power consumption.
      Valid values: 2400 - 3400, step by 33 (rounded down)
    $ref: /schemas/types.yaml#/definitions/uint32
    minimum: 2400
    maximum: 3400
    default: 2400

patternProperties:
  "^([a-z]+-)?led[01]?$":
    type: object
    $ref: common.yaml#
    unevaluatedProperties: false

    properties:
      led-sources:
        allOf:
          - minItems: 1
            maxItems: 2
            items:
              minimum: 0
              maximum: 1

      led-max-microamp:
        description: |
          Valid values for a LED connected to one FLED output:
            15625 - 250000, step by 15625 (rounded down)
          Valid values for a LED connected to both FLED outputs:
            15625 - 500000, step by 15625 (rounded down)

      flash-max-microamp:
        description: |
          Valid values for a single LED connected to one FLED output
          (boost mode must be turned off):
            15625 - 1000000, step by 15625 (rounded down)
          Valid values for a single LED connected to both FLED outputs:
            15625 - 1250000, step by 15625 (rounded down)
          Valid values for two LEDs case:
            15625 - 625000, step by 15625 (rounded down)

      flash-max-timeout-us:
        description: |
          Valid values: 62500 - 1000000, step by 62500 (rounded down)
        minimum: 62500
        maximum: 1000000

    required:
      - flash-max-microamp
      - flash-max-timeout-us
      - led-max-microamp
      - led-sources

required:
  - compatible

additionalProperties: false