~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/Documentation/devicetree/bindings/leds/awinic,aw200xx.yaml

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  2 %YAML 1.2
  3 ---
  4 $id: http://devicetree.org/schemas/leds/awinic,aw200xx.yaml#
  5 $schema: http://devicetree.org/meta-schemas/core.yaml#
  6 
  7 title: AWINIC AW200XX LED
  8 
  9 maintainers:
 10   - Martin Kurbanov <mmkurbanov@sberdevices.ru>
 11 
 12 description: |
 13   It is a matrix LED driver programmed via an I2C interface. Devices have
 14   a set of individually controlled leds and support 3 pattern controllers
 15   for auto breathing or group dimming control. Supported devices:
 16     - AW20036 (3x12) 36 LEDs
 17     - AW20054 (6x9)  54 LEDs
 18     - AW20072 (6x12) 72 LEDs
 19     - AW20108 (9x12) 108 LEDs
 20 
 21   For more product information please see the link below:
 22   aw20036 - https://www.awinic.com/en/productDetail/AW20036QNR#tech-docs
 23   aw20054 - https://www.awinic.com/en/productDetail/AW20054QNR#tech-docs
 24   aw20072 - https://www.awinic.com/en/productDetail/AW20072QNR#tech-docs
 25   aw20108 - https://www.awinic.com/en/productDetail/AW20108QNR#tech-docs
 26 
 27 properties:
 28   compatible:
 29     enum:
 30       - awinic,aw20036
 31       - awinic,aw20054
 32       - awinic,aw20072
 33       - awinic,aw20108
 34 
 35   reg:
 36     maxItems: 1
 37 
 38   "#address-cells":
 39     const: 1
 40 
 41   "#size-cells":
 42     const: 0
 43 
 44   enable-gpios:
 45     maxItems: 1
 46 
 47 patternProperties:
 48   "^led@[0-9a-f]+$":
 49     type: object
 50     $ref: common.yaml#
 51     unevaluatedProperties: false
 52 
 53     properties:
 54       reg:
 55         description:
 56           LED number
 57         maxItems: 1
 58 
 59       led-max-microamp:
 60         default: 9780
 61         description: |
 62           Note that a driver will take the minimum of all LED limits
 63           since the chip has a single global setting.
 64           The maximum output current of each LED is calculated by the
 65           following formula:
 66             IMAXled = 160000 * (592 / 600.5) * (1 / max-current-switch-number)
 67           And the minimum output current formula:
 68             IMINled = 3300 * (592 / 600.5) * (1 / max-current-switch-number)
 69           where max-current-switch-number is determined by led configuration
 70           and depends on how leds are physically connected to the led driver.
 71 
 72 allOf:
 73   - if:
 74       properties:
 75         compatible:
 76           contains:
 77             const: awinic,aw20036
 78     then:
 79       patternProperties:
 80         "^led@[0-9a-f]+$":
 81           properties:
 82             reg:
 83               items:
 84                 minimum: 0
 85                 maximum: 36
 86 
 87   - if:
 88       properties:
 89         compatible:
 90           contains:
 91             const: awinic,aw20054
 92     then:
 93       patternProperties:
 94         "^led@[0-9a-f]+$":
 95           properties:
 96             reg:
 97               items:
 98                 minimum: 0
 99                 maximum: 54
100 
101   - if:
102       properties:
103         compatible:
104           contains:
105             const: awinic,aw20072
106     then:
107       patternProperties:
108         "^led@[0-9a-f]+$":
109           properties:
110             reg:
111               items:
112                 minimum: 0
113                 maximum: 72
114 
115   - if:
116       properties:
117         compatible:
118           contains:
119             const: awinic,aw20108
120     then:
121       patternProperties:
122         "^led@[0-9a-f]+$":
123           properties:
124             reg:
125               items:
126                 minimum: 0
127                 maximum: 108
128 
129 required:
130   - compatible
131   - reg
132   - "#address-cells"
133   - "#size-cells"
134 
135 additionalProperties: false
136 
137 examples:
138   - |
139     #include <dt-bindings/gpio/gpio.h>
140     #include <dt-bindings/leds/common.h>
141 
142     i2c {
143         #address-cells = <1>;
144         #size-cells = <0>;
145 
146         led-controller@3a {
147             compatible = "awinic,aw20036";
148             reg = <0x3a>;
149             #address-cells = <1>;
150             #size-cells = <0>;
151             enable-gpios = <&gpio 3 GPIO_ACTIVE_HIGH>;
152 
153             led@0 {
154                 reg = <0x0>;
155                 color = <LED_COLOR_ID_RED>;
156                 led-max-microamp = <9780>;
157             };
158 
159             led@1 {
160                 reg = <0x1>;
161                 color = <LED_COLOR_ID_GREEN>;
162                 led-max-microamp = <9780>;
163             };
164 
165             led@2 {
166                 reg = <0x2>;
167                 color = <LED_COLOR_ID_BLUE>;
168                 led-max-microamp = <9780>;
169             };
170         };
171     };
172 
173 ...

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php