lkml.org 
[lkml]   [2021]   [Oct]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v9 1/2] dt-bindings: leds: Add Qualcomm Light Pulse Generator binding
On Thu 09 Sep 10:18 CDT 2021, Matthias Kaehlcke wrote:

> On Tue, Jun 22, 2021 at 08:50:38PM -0700, Bjorn Andersson wrote:
[..]
> > + - |
> > + #include <dt-bindings/leds/common.h>
> > +
> > + lpg {
> > + compatible = "qcom,pmi8994-lpg";
> > +
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + qcom,power-source = <1>;
> > +
> > + multi-led {
> > + color = <LED_COLOR_ID_RGB>;
> > + function = LED_FUNCTION_STATUS;
> > +
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + led@1 {
> > + reg = <1>;
> > + color = <LED_COLOR_ID_RED>;
> > + };
> > +
> > + led@2 {
> > + reg = <2>;
> > + color = <LED_COLOR_ID_GREEN>;
> > + };
> > +
> > + led@3 {
> > + reg = <3>;
> > + color = <LED_COLOR_ID_BLUE>;
> > + };
> > + };
> > + };
> > + - |
> > + lpg {
>
> nit: should the node be named 'lpg-pwm'?
>
> IIUC a PMIC .dtsi could have both a 'lpg' and a 'lpg-pwm' node, even though
> only one of them can be enabled at any time.
>

No, there's only the one "LPG", with N channels. The lpg exposes a pwm
chip and the child nodes may describe LEDs connected to the channels.
So this example is the configuration where there's no LEDs attached.

The compatible is "pwm", because the PM8916 lacks the pattern and RGB
blocks that makes up the LPG - and is hence named "PWM" in the datasheet
instead. So perhaps the example should be generically named "pwm"
instead.

In all other PMICs I know of the hardware block is named "lpg".

Regards,
Bjorn

> > + compatible = "qcom,pm8916-pwm";
> > + #pwm-cells = <2>;
> > + };

\
 
 \ /
  Last update: 2021-10-06 06:13    [W:0.089 / U:0.472 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site