diff mbox series

[v4,1/2] dt-bindings: leds: Add ROHM BD2606MVV LED driver

Message ID 20230414055341.335456-2-andreas@kemnade.info
State Superseded
Headers show
Series leds: Add a driver for the BD2606MVV | expand

Commit Message

Andreas Kemnade April 14, 2023, 5:53 a.m. UTC
Document ROHM BD2606MVV LED driver devicetree bindings.

Signed-off-by: Andreas Kemnade <andreas@kemnade.info>
Reviewed-by: Matti Vaittinen <mazziesaccount@gmail.com>
---
 .../bindings/leds/rohm,bd2606mvv.yaml         | 81 +++++++++++++++++++
 1 file changed, 81 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/leds/rohm,bd2606mvv.yaml

Comments

Andreas Kemnade April 14, 2023, 3:56 p.m. UTC | #1
On Fri, 14 Apr 2023 17:54:12 +0200
Andreas Kemnade <andreas@kemnade.info> wrote:

> On Fri, 14 Apr 2023 17:28:49 +0200
> Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:
> 
> > On 14/04/2023 07:53, Andreas Kemnade wrote:  
> > > Document ROHM BD2606MVV LED driver devicetree bindings.    
> > 
> > Subject: no improvements and no comments from your side. Why?
> >   
> old subject (v2):
> 
> dt-bindings: leds: ROHM BD2606MVV LED driver
> 
> Your comment:
> Subject: maybe drop "driver" (suggests it is for Linux drivers, although
> maybe it matches the actual hardware here?) and add missing verb, e.g.
> "Add ROHM ..."
> 
> New Subject (v3/4):
> dt-bindings: leds: Add ROHM BD2606MVV LED driver
> 
> What is still missing?
> 
ok, answering myself:
missing verb was added ("Add")

but
s/driver//
is missing

Sorry.

Regards,
Andreas
Krzysztof Kozlowski April 14, 2023, 9:17 p.m. UTC | #2
On 14/04/2023 17:54, Andreas Kemnade wrote:
> On Fri, 14 Apr 2023 17:28:49 +0200
> Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:
> 
>> On 14/04/2023 07:53, Andreas Kemnade wrote:
>>> Document ROHM BD2606MVV LED driver devicetree bindings.  
>>
>> Subject: no improvements and no comments from your side. Why?
>>
> old subject (v2):
> 
> dt-bindings: leds: ROHM BD2606MVV LED driver
> 
> Your comment:
> Subject: maybe drop "driver" (suggests it is for Linux drivers, although
> maybe it matches the actual hardware here?) and add missing verb, e.g.
> "Add ROHM ..."
> 
> New Subject (v3/4):
> dt-bindings: leds: Add ROHM BD2606MVV LED driver
> 
> What is still missing?

There is still "driver". Comment was: drop "driver". Where is it dropped?

If you do not agree, sure, just respond with something.

Best regards,
Krzysztof
Andreas Kemnade April 16, 2023, 9:25 p.m. UTC | #3
Hi,

On Fri, 14 Apr 2023 23:17:56 +0200
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:

> On 14/04/2023 17:54, Andreas Kemnade wrote:
> > On Fri, 14 Apr 2023 17:28:49 +0200
> > Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:
> >   
> >> On 14/04/2023 07:53, Andreas Kemnade wrote:  
> >>> Document ROHM BD2606MVV LED driver devicetree bindings.    
> >>
> >> Subject: no improvements and no comments from your side. Why?
> >>  
> > old subject (v2):
> > 
> > dt-bindings: leds: ROHM BD2606MVV LED driver
> > 
> > Your comment:
> > Subject: maybe drop "driver" (suggests it is for Linux drivers, although
> > maybe it matches the actual hardware here?) and add missing verb, e.g.
> > "Add ROHM ..."
> > 
> > New Subject (v3/4):
> > dt-bindings: leds: Add ROHM BD2606MVV LED driver
> > 
> > What is still missing?  
> 
> There is still "driver". Comment was: drop "driver". Where is it dropped?
> 
> If you do not agree, sure, just respond with something.
> 
I am fine with both. On one hand BD2606MVV is not a LED by itself
but LEDs can be connected to it. so the chip itself can be called LED driver.

But on the other hand I think that holds true for everything in drivers/leds
and binding/leds and we do not call the subsystem leddriver.
So there are reasons for and against "driver" in the subject line.

Regards,
Andreas
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/leds/rohm,bd2606mvv.yaml b/Documentation/devicetree/bindings/leds/rohm,bd2606mvv.yaml
new file mode 100644
index 0000000000000..14700a2e5feaa
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/rohm,bd2606mvv.yaml
@@ -0,0 +1,81 @@ 
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/rohm,bd2606mvv.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: ROHM BD2606MVV LED controller
+
+maintainers:
+  - Andreas Kemnade <andreas@kemnade.info>
+
+description:
+  The BD2606 MVV is a programmable LED controller connected via I2C that can
+  drive 6 separate lines. Each of them can be individually switched on and off,
+  but the brightness setting is shared between pairs of them.
+
+  Datasheet is available at
+  https://fscdn.rohm.com/en/products/databook/datasheet/ic/power/led_driver/bd2606mvv_1-e.pdf
+
+properties:
+  compatible:
+    const: rohm,bd2606mvv
+
+  reg:
+    maxItems: 1
+
+  "#address-cells":
+    const: 1
+
+  "#size-cells":
+    const: 0
+
+  enable-gpios:
+    maxItems: 1
+    description: GPIO pin to enable/disable the device.
+
+patternProperties:
+  "^led@[0-6]$":
+    type: object
+    $ref: common.yaml#
+    unevaluatedProperties: false
+
+    properties:
+      reg:
+        minimum: 0
+        maximum: 6
+
+    required:
+      - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/leds/common.h>
+
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        led-controller@66 {
+            compatible = "rohm,bd2606mvv";
+            reg = <0x66>;
+            #address-cells = <1>;
+            #size-cells = <0>;
+
+            led@0 {
+                reg = <0x0>;
+                color = <LED_COLOR_ID_RED>;
+                function = LED_FUNCTION_POWER;
+            };
+
+            led@2 {
+                reg = <0x2>;
+                color = <LED_COLOR_ID_WHITE>;
+                function = LED_FUNCTION_STATUS;
+            };
+        };
+    };
+
+...