0001 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/leds/regulator-led.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006
0007 title: Device Tree Bindings for Regulator LEDs
0008
0009 maintainers:
0010 - Linus Walleij <linus.walleij@linaro.org>
0011
0012 description: |
0013 Regulator LEDs are powered by a single regulator such that they can
0014 be turned on or off by enabling or disabling the regulator. The available
0015 brightness settings will be inferred from the available voltages on the
0016 regulator, and any constraints on the voltage or current will need to be
0017 specified on the regulator.
0018
0019 allOf:
0020 - $ref: common.yaml#
0021
0022 properties:
0023 $nodename:
0024 pattern: '^led.*$'
0025
0026 compatible:
0027 const: regulator-led
0028
0029 vled-supply:
0030 description:
0031 The regulator controlling the current to the LED.
0032
0033 function: true
0034 color: true
0035 linux,default-trigger: true
0036 default-state: true
0037
0038 required:
0039 - compatible
0040 - vled-supply
0041
0042 additionalProperties: false
0043
0044 examples:
0045 - |
0046 #include <dt-bindings/leds/common.h>
0047
0048 led-heartbeat {
0049 compatible = "regulator-led";
0050 vled-supply = <®ulator>;
0051 function = LED_FUNCTION_STATUS;
0052 color = <LED_COLOR_ID_BLUE>;
0053 linux,default-trigger = "heartbeat";
0054 };
0055 ...