Akinobu On 10/22/19 10:06 AM, Akinobu Mita wrote:
Add DT binding for leds-meter.
$subject should be dt-bindings: leds: Add leds-meter binding And this patch should be first in the series
Cc: Rob Herring <robh+dt@xxxxxxxxxx> Cc: Mark Rutland <mark.rutland@xxxxxxx> Cc: Bjorn Andersson <bjorn@xxxxxxx> Cc: Tomi Valkeinen <tomi.valkeinen@xxxxxx> Cc: Jean-Jacques Hiblot <jjhiblot@xxxxxx> Cc: Jacek Anaszewski <jacek.anaszewski@xxxxxxxxx> Cc: Pavel Machek <pavel@xxxxxx> Cc: Dan Murphy <dmurphy@xxxxxx> Signed-off-by: Akinobu Mita <akinobu.mita@xxxxxxxxx> --- .../devicetree/bindings/leds/leds-meter.yaml | 42 ++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 Documentation/devicetree/bindings/leds/leds-meter.yaml diff --git a/Documentation/devicetree/bindings/leds/leds-meter.yaml b/Documentation/devicetree/bindings/leds/leds-meter.yaml new file mode 100644 index 0000000..d5dfa261 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/leds-meter.yaml @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/leds-meter.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Generic LED level meter + +maintainers: + - Akinobu Mita <akinobu.mita@xxxxxxxxx> + +description: + Generic LED level meter consists of multiple LED devices by different drivers. + +properties: + compatible: + const: meter-leds + + leds:
This seems a bit generic for the property name
+ $ref: /schemas/types.yaml#/definitions/phandle-array + minItems: 1 + description: List of phandles to LED node that are members of a level meter. + + brightness-weights: + $ref: /schemas/types.yaml#/definitions/uint32-array + minItems: 1 + description: Each integer represents a contribution ratio within a level + meter.
This description is a bit vague I would not be sure what I would set this to.
Dan
+ +required: + - compatible + - leds + +examples: + - | + leds { + compatible = "meter-leds"; + leds = <&led0>, <&led1>, <&led2>, <&led3>; + brightness-weights = <3 1 1 1>; + }; + +...