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-lp5860.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: LED driver for LP5860 RGB LED from Texas Instruments. 8 9maintainers: 10 - Steffen Trumtrar <kernel@pengutronix.de> 11 12description: | 13 The LP5860 is multi-channel, I2C and SPI RGB LED Driver that can group RGB LEDs 14 into a LED group or control them individually. 15 16 For more product information please see the link below: 17 https://www.ti.com/lit/ds/symlink/lp5860.pdf 18 19allOf: 20 - $ref: /schemas/spi/spi-peripheral-props.yaml# 21 22properties: 23 compatible: 24 enum: 25 - ti,lp5860 26 27 reg: 28 maxItems: 1 29 30 '#address-cells': 31 const: 1 32 33 '#size-cells': 34 const: 0 35 36 enable-gpios: 37 maxItems: 1 38 description: | 39 GPIO attached to the chip's enable pin (VIO_EN). 40 41patternProperties: 42 '^multi-led@[0-9a-f]+$': 43 type: object 44 $ref: leds-class-multicolor.yaml# 45 unevaluatedProperties: false 46 47 properties: 48 reg: 49 minimum: 0 50 maximum: 198 51 description: 52 This property denotes the LED module number that is used 53 for the child node. 54 55 '#address-cells': 56 const: 1 57 58 '#size-cells': 59 const: 0 60 61 patternProperties: 62 "^led@[0-9a-f]+$": 63 type: object 64 $ref: common.yaml# 65 unevaluatedProperties: false 66 67 properties: 68 reg: 69 maxItems: 1 70 71 required: 72 - reg 73 74required: 75 - compatible 76 - reg 77 78unevaluatedProperties: false 79 80examples: 81 - | 82 #include <dt-bindings/gpio/gpio.h> 83 #include <dt-bindings/leds/common.h> 84 85 spi { 86 #address-cells = <1>; 87 #size-cells = <0>; 88 89 led-controller@0 { 90 compatible = "ti,lp5860"; 91 reg = <0x0>; 92 enable-gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>; 93 #address-cells = <1>; 94 #size-cells = <0>; 95 96 multi-led@0 { 97 #address-cells = <1>; 98 #size-cells = <0>; 99 reg = <0x0>; 100 color = <LED_COLOR_ID_RGB>; 101 102 led@0 { 103 reg = <0x0>; 104 color = <LED_COLOR_ID_RED>; 105 }; 106 107 led@1 { 108 reg = <0x1>; 109 color = <LED_COLOR_ID_GREEN>; 110 }; 111 112 led@2 { 113 reg = <0x2>; 114 color = <LED_COLOR_ID_BLUE>; 115 }; 116 }; 117 }; 118 }; 119