Merge tag 'tee-fix-for-v5.10' of git://git.linaro.org:/people/jens.wiklander/linux...
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / leds / leds-lp50xx.yaml
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/leds/leds-lp50xx.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: LED driver for LP50XX RGB LED from Texas Instruments.
8
9 maintainers:
10   - Dan Murphy <dmurphy@ti.com>
11
12 description: |
13   The LP50XX is multi-channel, I2C RGB LED Drivers that can group RGB LEDs into
14   a LED group or control them individually.
15
16   The difference in these RGB LED drivers is the number of supported RGB
17   modules.
18
19   For more product information please see the link below:
20   https://www.ti.com/lit/ds/symlink/lp5012.pdf
21   https://www.ti.com/lit/ds/symlink/lp5024.pdf
22   https://www.ti.com/lit/ds/symlink/lp5036.pdf
23
24 properties:
25   compatible:
26     enum:
27       - ti,lp5009
28       - ti,lp5012
29       - ti,lp5018
30       - ti,lp5024
31       - ti,lp5030
32       - ti,lp5036
33
34   reg:
35     maxItems: 1
36     description:
37       I2C slave address
38       lp5009/12 - 0x14, 0x15, 0x16, 0x17
39       lp5018/24 - 0x28, 0x29, 0x2a, 0x2b
40       lp5030/36 - 0x30, 0x31, 0x32, 0x33
41
42   enable-gpios:
43     maxItems: 1
44     description: GPIO pin to enable/disable the device.
45
46   vled-supply:
47     description: LED supply.
48
49 patternProperties:
50   '^multi-led@[0-9a-f]$':
51     type: object
52     allOf:
53       - $ref: leds-class-multicolor.yaml#
54     properties:
55       reg:
56         minItems: 1
57         maxItems: 12
58         description:
59           This property denotes the LED module number(s) that is used on the
60           for the child node.  The LED modules can either be used stand alone
61           or grouped into a module bank.
62
63     patternProperties:
64       "(^led-[0-9a-f]$|led)":
65         type: object
66         $ref: common.yaml#
67
68 required:
69   - compatible
70   - reg
71
72 examples:
73   - |
74    #include <dt-bindings/gpio/gpio.h>
75    #include <dt-bindings/leds/common.h>
76
77    i2c {
78        #address-cells = <1>;
79        #size-cells = <0>;
80
81        led-controller@14 {
82            compatible = "ti,lp5009";
83            reg = <0x14>;
84            #address-cells = <1>;
85            #size-cells = <0>;
86            enable-gpios = <&gpio1 16>;
87
88            multi-led@1 {
89                #address-cells = <1>;
90                #size-cells = <0>;
91                reg = <0x1>;
92                color = <LED_COLOR_ID_RGB>;
93                function = LED_FUNCTION_CHARGING;
94
95                led-0 {
96                    color = <LED_COLOR_ID_RED>;
97                };
98
99                led-1 {
100                    color = <LED_COLOR_ID_GREEN>;
101                };
102
103                led-2 {
104                    color = <LED_COLOR_ID_BLUE>;
105                };
106           };
107
108           multi-led@2 {
109             #address-cells = <1>;
110             #size-cells = <2>;
111             reg = <0x2 0x3 0x5>;
112             color = <LED_COLOR_ID_RGB>;
113             function = LED_FUNCTION_STANDBY;
114
115             led-6 {
116               color = <LED_COLOR_ID_RED>;
117             };
118
119             led-7 {
120               color = <LED_COLOR_ID_GREEN>;
121             };
122
123             led-8 {
124               color = <LED_COLOR_ID_BLUE>;
125             };
126          };
127        };
128     };
129
130 ...