All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 1/2] dt-bindings: leds: lp50xx: correct reg/unit addresses in example
@ 2022-05-24  7:08 Krzysztof Kozlowski
  2022-05-24  7:08 ` [PATCH v2 2/2] dt-bindings: leds: fix indentation in examples Krzysztof Kozlowski
  2022-05-24 18:34 ` [PATCH v2 1/2] dt-bindings: leds: lp50xx: correct reg/unit addresses in example Rob Herring
  0 siblings, 2 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-24  7:08 UTC (permalink / raw)
  To: Pavel Machek, Rob Herring, Krzysztof Kozlowski, Dan Murphy,
	Jacek Anaszewski, Sven Schwermer, linux-leds, devicetree,
	linux-kernel
  Cc: Krzysztof Kozlowski, Kyle Swenson

The multi-led node defined address/size cells, so it intended to have
children with unit addresses.

The second multi-led's reg property defined three LED indexes within one
reg item, which is not correct - these are three separate items.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

---

Changes since v1:
1. Correct multi-led unit address as well (Rob).

Cc: Kyle Swenson <kyle.swenson@est.tech>
---
 .../devicetree/bindings/leds/leds-lp50xx.yaml | 24 ++++++++++++-------
 1 file changed, 15 insertions(+), 9 deletions(-)

diff --git a/Documentation/devicetree/bindings/leds/leds-lp50xx.yaml b/Documentation/devicetree/bindings/leds/leds-lp50xx.yaml
index f12fe5b53f30..29ce0cb7d449 100644
--- a/Documentation/devicetree/bindings/leds/leds-lp50xx.yaml
+++ b/Documentation/devicetree/bindings/leds/leds-lp50xx.yaml
@@ -99,35 +99,41 @@ examples:
                color = <LED_COLOR_ID_RGB>;
                function = LED_FUNCTION_CHARGING;
 
-               led-0 {
+               led@0 {
+                   reg = <0x0>;
                    color = <LED_COLOR_ID_RED>;
                };
 
-               led-1 {
+               led@1 {
+                   reg = <0x1>;
                    color = <LED_COLOR_ID_GREEN>;
                };
 
-               led-2 {
+               led@2 {
+                   reg = <0x2>;
                    color = <LED_COLOR_ID_BLUE>;
                };
           };
 
-          multi-led@2 {
+          multi-led@3 {
             #address-cells = <1>;
-            #size-cells = <2>;
-            reg = <0x2 0x3 0x5>;
+            #size-cells = <0>;
+            reg = <0x3>, <0x4>, <0x5>;
             color = <LED_COLOR_ID_RGB>;
             function = LED_FUNCTION_STANDBY;
 
-            led-6 {
+            led@3 {
+              reg = <0x3>;
               color = <LED_COLOR_ID_RED>;
             };
 
-            led-7 {
+            led@4 {
+              reg = <0x4>;
               color = <LED_COLOR_ID_GREEN>;
             };
 
-            led-8 {
+            led@5 {
+              reg = <0x5>;
               color = <LED_COLOR_ID_BLUE>;
             };
          };
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-05-24 18:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-24  7:08 [PATCH v2 1/2] dt-bindings: leds: lp50xx: correct reg/unit addresses in example Krzysztof Kozlowski
2022-05-24  7:08 ` [PATCH v2 2/2] dt-bindings: leds: fix indentation in examples Krzysztof Kozlowski
2022-05-24 18:35   ` Rob Herring
2022-05-24 18:34 ` [PATCH v2 1/2] dt-bindings: leds: lp50xx: correct reg/unit addresses in example Rob Herring

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.