From: Nam Tran <trannamatk@gmail.com>
To: krzk+dt@kernel.org
Cc: lee@kernel.org, pavel@kernel.org, robh@kernel.org,
conor+dt@kernel.org, corbet@lwn.net, linux-leds@vger.kernel.org,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
linux-doc@vger.kernel.org
Subject: Re: [PATCH v9 1/4] dt-bindings: leds: add TI/National Semiconductor LP5812 LED Driver
Date: Tue, 17 Jun 2025 23:29:47 +0700 [thread overview]
Message-ID: <20250617162947.16955-1-trannamatk@gmail.com> (raw)
In-Reply-To: <20250611-nimble-archetypal-raptor-eadcb6@kuoka>
On Wed, 11 Jun 2025, Krzysztof Kozlowski wrote:
> > +patternProperties:
> > + "^led@[0-3]$":
> > + type: object
> > + $ref: common.yaml#
> > + unevaluatedProperties: false
> > +
> > + properties:
> > + led-cur:
> > + $ref: /schemas/types.yaml#/definitions/uint8
> > + description: |
> > + LED current in 0.1 mA steps (e.g., 150 = 15.0 mA; 0 if not connected)
> > + minimum: 0
> > + maximum: 255
> > +
> > + max-cur:
> > + $ref: /schemas/types.yaml#/definitions/uint8
> > + description: Maximum allowed current in 0.1 mA steps
> > +
> > + reg:
> > + minimum: 0
> > + maximum: 3
>
> Place properties according to DTS coding style.
Got it! I'll update the property order accordingly.
> > + '^multi-led@[4-7]$':
> > + type: object
> > + $ref: leds-class-multicolor.yaml#
> > + unevaluatedProperties: false
> > +
> > + properties:
> > + reg:
> > + minimum: 4
> > + maximum: 7
> > +
> > + '#address-cells':
>
> Don't mix quotes. Either ' or "
I'll use consistent ".
> > + const: 1
> > +
> > + '#size-cells':
> > + const: 0
> > +
> > + patternProperties:
> > + "^led@[4-9a-f]$":
> > + type: object
> > + $ref: common.yaml#
> > + unevaluatedProperties: false
> > +
> > + properties:
> > + led-cur:
> > + $ref: /schemas/types.yaml#/definitions/uint8
>
> No, use existing led common properties. Also observe the units - this is
> not uint8 but a defined type for microamp, see property-units in
> dtschema.
>
> > + description: |
> > + LED current in 0.1 mA steps (e.g., 150 = 15.0 mA; 0 if not connected)
> > + minimum: 0
> > + maximum: 255
> > +
> > + max-cur:
> > + $ref: /schemas/types.yaml#/definitions/uint8
>
> No, use existing led common properties. Same everywhere.
I'll replace max-cur with the standard led-max-microamp.
I'll remove led-cur as there's no equivalent LED common property to represent it.
The LED current can be configured runtime via the led_current sysfs.
> > +examples:
> > + - |
> > + #include <dt-bindings/leds/common.h>
> > +
> > + i2c {
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + led-controller@1b {
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > + compatible = "ti,lp5812";
> > + reg = <0x1b>;
> > + vcc-supply = <&vdd_3v3_reg>;
> > +
> > + led@0 {
> > + reg = <0x0>;
>
>
> Messed/mixed indentation.
I'll fix it.
> BTW, such significant binding change at v9, invalidting reviews and
> rewriting the binding completely, is surprising.
Understood. I restructured the binding in v9 to align with leds-class-multicolor.yaml
and better represent the LP5812 hierarchy.
I'll make sure to highlight such major changes more clearly in future revisions.
Appreciate your time and feedback.
Best regards,
Nam Tran
next prev parent reply other threads:[~2025-06-17 16:29 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-10 17:43 [PATCH v9 0/4] leds: add new LED driver for TI LP5812 Nam Tran
2025-06-10 17:43 ` [PATCH v9 1/4] dt-bindings: leds: add TI/National Semiconductor LP5812 LED Driver Nam Tran
2025-06-11 8:24 ` Krzysztof Kozlowski
2025-06-17 16:29 ` Nam Tran [this message]
2025-06-10 17:43 ` [PATCH v5] test Nam Tran
2025-06-12 10:03 ` Lee Jones
2025-06-17 17:46 ` Nam Tran
2025-06-10 17:43 ` [PATCH v9 2/4] leds: add TI/National Semiconductor LP5812 LED Driver Nam Tran
2025-06-10 18:13 ` Randy Dunlap
2025-06-17 16:50 ` Nam Tran
2025-06-10 21:07 ` Christophe JAILLET
2025-06-17 17:30 ` Nam Tran
2025-06-16 18:37 ` kernel test robot
2025-06-10 17:43 ` [PATCH v9 3/4] docs: ABI: Document LP5812 LED sysfs interfaces Nam Tran
2025-06-10 17:43 ` [PATCH v9 4/4] docs: leds: Document TI LP5812 LED driver Nam Tran
2025-06-10 17:55 ` [PATCH v9 0/4] leds: add new LED driver for TI LP5812 Nam Tran
2025-06-11 6:59 ` Krzysztof Kozlowski
2025-06-17 15:40 ` Nam Tran
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250617162947.16955-1-trannamatk@gmail.com \
--to=trannamatk@gmail.com \
--cc=conor+dt@kernel.org \
--cc=corbet@lwn.net \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=lee@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=pavel@kernel.org \
--cc=robh@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).