diff mbox series

[v3,1/2] dt: bindings: lm3692x: Add bindings for lm3692x LED driver

Message ID 20171115194203.13572-1-dmurphy@ti.com
State New
Headers show
Series [v3,1/2] dt: bindings: lm3692x: Add bindings for lm3692x LED driver | expand

Commit Message

Dan Murphy Nov. 15, 2017, 7:42 p.m. UTC
This adds the devicetree bindings for the LM3692x
I2C LED string driver.

Acked-by: Pavel Machek <pavel@ucw.cz>

Signed-off-by: Dan Murphy <dmurphy@ti.com>

---

v3 - No changes
v2 - No changes - https://patchwork.kernel.org/patch/10056677/

 .../devicetree/bindings/leds/leds-lm3692x.txt      | 28 ++++++++++++++++++++++
 1 file changed, 28 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/leds/leds-lm3692x.txt

-- 
2.15.0.124.g7668cbc60

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Jacek Anaszewski Nov. 15, 2017, 8:15 p.m. UTC | #1
Hi Dan,

Thanks for the patch.

On 11/15/2017 08:42 PM, Dan Murphy wrote:
> This adds the devicetree bindings for the LM3692x

> I2C LED string driver.

> 

> Acked-by: Pavel Machek <pavel@ucw.cz>

> Signed-off-by: Dan Murphy <dmurphy@ti.com>

> ---

> 

> v3 - No changes

> v2 - No changes - https://patchwork.kernel.org/patch/10056677/

> 

>  .../devicetree/bindings/leds/leds-lm3692x.txt      | 28 ++++++++++++++++++++++

>  1 file changed, 28 insertions(+)

>  create mode 100644 Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> 

> diff --git a/Documentation/devicetree/bindings/leds/leds-lm3692x.txt b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> new file mode 100644

> index 000000000000..cfef67bd4100

> --- /dev/null

> +++ b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> @@ -0,0 +1,28 @@

> +* Texas Instruments - LM3692x Highly Efficient Dual-String White LED Driver

> +

> +The LM36922 is an ultra-compact, highly efficient,

> +two string white-LED driver designed for LCD display

> +backlighting.


Shouldn't the driver be targeted for backlight subsystem then?

Adding backlight maintainers.

Best regards,
Jacek Anaszewski

> +Required properties:

> +	- compatible:

> +		"ti,lm3692x"

> +	- reg -  I2C slave address

> +

> +Optional properties:

> +	- label - Used for naming LEDs

> +	- enable-gpio - gpio pin to enable/disable the device.

> +	- supply - "vled" - LED supply

> +

> +Example:

> +

> +leds: leds@6 {

> +	compatible = "ti,lm3692x";

> +	reg = <0x36>;

> +	label = "backlight_cluster";

> +	enable-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;

> +	vled-supply = <&vbatt>;

> +}

> +

> +For more product information please see the link below:

> +http://www.ti.com/lit/ds/snvsa29/snvsa29.pdf

> 


--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Pavel Machek Nov. 15, 2017, 10:23 p.m. UTC | #2
Hi!

> > Shouldn't the driver be targeted for backlight subsystem then?

> > 

> > Adding backlight maintainers.

> > 

> 

> Great point!  I was not aware of the backlight subsystem.

> 

> Looks like I need to create a back light version as well.

> 

> Like the lp8788 did since this can be used as a LED driver beyond

> display back lighting.


No, definitely not two drivers for lp8788 hardware.

If that does not yet exist... you want to create glue layer to be able
to use LED as a display backlight. (It may already exist, no idea).

...

Actually or maybe a LED trigger. Just set LED's trigger to "this is
display backlight".

Other solutions are acceptable, but not two hardware drivers.

Thanks,
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Rob Herring Nov. 16, 2017, 3:41 p.m. UTC | #3
On Wed, Nov 15, 2017 at 01:42:02PM -0600, Dan Murphy wrote:
> This adds the devicetree bindings for the LM3692x

> I2C LED string driver.

> 

> Acked-by: Pavel Machek <pavel@ucw.cz>

> Signed-off-by: Dan Murphy <dmurphy@ti.com>

> ---

> 

> v3 - No changes

> v2 - No changes - https://patchwork.kernel.org/patch/10056677/

> 

>  .../devicetree/bindings/leds/leds-lm3692x.txt      | 28 ++++++++++++++++++++++

>  1 file changed, 28 insertions(+)

>  create mode 100644 Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> 

> diff --git a/Documentation/devicetree/bindings/leds/leds-lm3692x.txt b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> new file mode 100644

> index 000000000000..cfef67bd4100

> --- /dev/null

> +++ b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt

> @@ -0,0 +1,28 @@

> +* Texas Instruments - LM3692x Highly Efficient Dual-String White LED Driver

> +

> +The LM36922 is an ultra-compact, highly efficient,

> +two string white-LED driver designed for LCD display

> +backlighting.

> +

> +Required properties:

> +	- compatible:

> +		"ti,lm3692x"


Don't use wildcards in compatible strings.

> +	- reg -  I2C slave address

> +

> +Optional properties:

> +	- label - Used for naming LEDs

> +	- enable-gpio - gpio pin to enable/disable the device.


enable-gpios is the preferred form.

> +	- supply - "vled" - LED supply


vled-supply - ...

> +

> +Example:

> +

> +leds: leds@6 {

> +	compatible = "ti,lm3692x";

> +	reg = <0x36>;

> +	label = "backlight_cluster";

> +	enable-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;

> +	vled-supply = <&vbatt>;

> +}

> +

> +For more product information please see the link below:

> +http://www.ti.com/lit/ds/snvsa29/snvsa29.pdf

> -- 

> 2.15.0.124.g7668cbc60

> 

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Dan Murphy Nov. 16, 2017, 9:40 p.m. UTC | #4
On 11/16/2017 02:36 PM, Rob Herring wrote:
> On Thu, Nov 16, 2017 at 2:11 PM, Pavel Machek <pavel@ucw.cz> wrote:

>> Hi!

>>

>>>>> +Required properties:

>>>>> +  - compatible:

>>>>> +          "ti,lm3692x"

>>>>

>>>> Don't use wildcards in compatible strings.

>>>

>>> Do you mean to remove the x?  How do we denote a family of parts

>>> then?

>>

>> I guess you should specify the exact chip.

>>

>> Which will present interesting problem for me on Nokia N9/N950; in one

>> case, compatible chip is produced by two companies, and it looks like

>> some machines have one and some have the other; but we'd like to share

>> the dts as user has no chance telling them apart (and it is not

>> important, anyway).

>>

>> In second case, chip is refered as APDS990X and I don't know where to

>> get more exact data.

> 

> There's always exceptions to rules. Just make the case for it. IIRC,

> there was the same case for the BT chip.

> 


Not sure how I got looped into the dts fun.  But I am going to call out the specific chips out in the
compatible strings.  There are currently only 2 devices supported by this driver.  The delta
between the chips is one supports a third string of LEDs.  1 bit in 1 register.

Dan

> Rob

> 



-- 
------------------
Dan Murphy
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Pavel Machek Nov. 17, 2017, 11:58 p.m. UTC | #5
Hi!

> >> Well.. if it can control other LEDs than just backlight, I believe it

> >> can stay in the LED subsystem.

> > 

> > I also agree with your opinion.

> 

> I will make the necessary changes for v4.


I'm not sure if you need to make any changes. Just add default trigger
to the dts and you should be done.

> Just a heads up I won't be posting v4 until after the US holiday so you

> don't think I abandoned everything.


:-)
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/leds/leds-lm3692x.txt b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt
new file mode 100644
index 000000000000..cfef67bd4100
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/leds-lm3692x.txt
@@ -0,0 +1,28 @@ 
+* Texas Instruments - LM3692x Highly Efficient Dual-String White LED Driver
+
+The LM36922 is an ultra-compact, highly efficient,
+two string white-LED driver designed for LCD display
+backlighting.
+
+Required properties:
+	- compatible:
+		"ti,lm3692x"
+	- reg -  I2C slave address
+
+Optional properties:
+	- label - Used for naming LEDs
+	- enable-gpio - gpio pin to enable/disable the device.
+	- supply - "vled" - LED supply
+
+Example:
+
+leds: leds@6 {
+	compatible = "ti,lm3692x";
+	reg = <0x36>;
+	label = "backlight_cluster";
+	enable-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;
+	vled-supply = <&vbatt>;
+}
+
+For more product information please see the link below:
+http://www.ti.com/lit/ds/snvsa29/snvsa29.pdf