Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1222741imm; Wed, 8 Aug 2018 13:00:14 -0700 (PDT) X-Google-Smtp-Source: AA+uWPyPvTgerLvo6Dx2OwD0/6/omxkIcBI+rMrXoVQQCc5+yAI1jvpl4hckhzcLXapbA97GF6Lm X-Received: by 2002:a65:5307:: with SMTP id m7-v6mr3903162pgq.431.1533758414023; Wed, 08 Aug 2018 13:00:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533758413; cv=none; d=google.com; s=arc-20160816; b=s1ha5QzLdCFJRNXEKYeiC8pl35MY2xuVJKIJiP5s4N20epwZEQBgOsiZLuHC7GmyOo h5suQX6OlmYmNmYHmBPVeAGuvNKWIzSzeTDHTcJka1f7bJUnM7VmUpl3mZOjKPdchUNu oRVKIQDyJwjZpi25uYROnRJW50rXl2PwqBwR0S3K212dL4MEhRI6qAYtlig3Zxe1x1hf mpOKHaosLr+PYrjtmc+OWV6OmPHOoxVJjB9jKiowpBB5+kqFztyXv/UZZihGg25dqQAV XEsC3r6/QwoGN56DzX8JWYwcUbTd1rhYzH/QxXoOFSX/8sUZfRYt4tTLkdjtkEs8YnSY y0zQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=xvemnyCkKPXtK3FRp9tV1+uGZ857ZtOAGIuvDNrwOjs=; b=yhxOINbA9DrcUu/kNDAz6ZGCJ79ERvVB/J15dSzZEZml0CNCiBUmpxbAQawooxjOoI yQc1GtK/wvIs+cGIMgj1EJzwHDLmCMrU2hfxXgjrQj0d1BbwzUDxW4k2HdmfX30vfGOw 2wgiuOEY7Gmx90uo8aknp23/+rdGUYWE2QXRNz4ZN7FEfvyMQZtyvr6QpY2DpF6HODuR nkX24707Kf6AeQ21AmadljwrH7SoHeVxSWJFFHPHT9sfEpimTsS4VFohbV1QzqjbTXkl FdzWOJYKY3tR3VM5Ans6Ya35GVdh6JJlEWyb1mQ/OE4uNMx7sH38bp+ftC1nRjnjAmtq tocQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n4-v6si4976151pgi.69.2018.08.08.12.59.59; Wed, 08 Aug 2018 13:00:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731069AbeHHWUU (ORCPT + 99 others); Wed, 8 Aug 2018 18:20:20 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:38324 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729703AbeHHWUT (ORCPT ); Wed, 8 Aug 2018 18:20:19 -0400 Received: by atrey.karlin.mff.cuni.cz (Postfix, from userid 512) id 156548064C; Wed, 8 Aug 2018 21:59:04 +0200 (CEST) Date: Wed, 8 Aug 2018 21:59:03 +0200 From: Pavel Machek To: Dan Murphy Cc: robh+dt@kernel.org, jacek.anaszewski@gmail.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org Subject: Re: [PATCH v2 1/2] dt: bindings: lm3697: Add bindings for lm3697 driver Message-ID: <20180808195903.GB20912@amd> References: <20180807160442.8937-1-dmurphy@ti.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5I6of5zJg18YgZEa" Content-Disposition: inline In-Reply-To: <20180807160442.8937-1-dmurphy@ti.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --5I6of5zJg18YgZEa Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue 2018-08-07 11:04:41, Dan Murphy wrote: > Add the device tree bindings for the lm3697 > led driver for backlighting and display. >=20 > Signed-off-by: Dan Murphy > --- >=20 > v2 - Fixed subject and patch commit message - https://lore.kernel.org/pat= chwork/patch/971326/ >=20 > .../devicetree/bindings/leds/leds-lm3697.txt | 64 +++++++++++++++++++ > 1 file changed, 64 insertions(+) > create mode 100644 Documentation/devicetree/bindings/leds/leds-lm3697.txt >=20 > diff --git a/Documentation/devicetree/bindings/leds/leds-lm3697.txt b/Doc= umentation/devicetree/bindings/leds/leds-lm3697.txt > new file mode 100644 > index 000000000000..7b8e490f1ea1 > --- /dev/null > +++ b/Documentation/devicetree/bindings/leds/leds-lm3697.txt > @@ -0,0 +1,64 @@ > +* Texas Instruments - LM3697 Highly Efficient White LED Driver > + > +The LM3697 11-bit LED driver provides high- > +performance backlight dimming for 1, 2, or 3 series > +LED strings while delivering up to 90% efficiency. > + > +This device is suitable for Display and Keypad Lighting > + > +Required properties: > + - compatible: > + "ti,lm3967" > + - reg : I2C slave address > + - #address-cells : 1 > + - #size-cells : 0 > + - control-bank-cfg - : Indicates which sink is connected to which contr= ol bank > + 0 - All HVLED outputs are controlled by bank A > + 1 - HVLED1 is controlled bank B, HVLED2/3 are controlled by bank A > + 2 - HVLED2 is controlled bank B, HVLED1/3 are controlled by bank A > + 3 - HVLED1/2 are controlled by bank B, HVLED3 is controlled by bank A > + 4 - HVLED3 is controlled by bank B, HVLED1/2 are controlled by bank A > + 5 - HVLED1/3 is controlled by bank B, HVLED2 is controlled by bank A > + 6 - (default) HVLED1 is controlled by bank A, HVLED2/3 are controlled = by bank B > + 7 - All HVLED outputs are controlled by bank B This is quite long way to describe a bitmask, no? Could we make it so that control-bank-cfg is not needed? > +Optional properties: > + - enable-gpios : gpio pin to enable/disable the device. > + - vled-supply : LED supply > + > +Required child properties: > + - reg : 0 - LED is Controlled by bank A > + 1 - LED is Controlled by bank B Can we compute control-bank-cfg from this? > +Optional child properties: > + - label : see Documentation/devicetree/bindings/leds/common.txt > + - linux,default-trigger : > + see Documentation/devicetree/bindings/leds/common.txt > + > +Example: > + > +led-controller@36 { > + compatible =3D "ti,lm3967"; > + reg =3D <0x36>; > + #address-cells =3D <1>; > + #size-cells =3D <0>; > + > + enable-gpios =3D <&gpio1 28 GPIO_ACTIVE_HIGH>; > + vled-supply =3D <&vbatt>; > + control-bank-cfg =3D <0>; > + > + led@0 { > + reg =3D <0>; > + label =3D "white:first_backlight_cluster"; > + linux,default-trigger =3D "backlight"; > + }; > + > + led@1 { > + reg =3D <1>; > + label =3D "white:second_backlight_cluster"; > + linux,default-trigger =3D "frontlight"; > + }; > +} Does the example show correct config? AFAICT all controls go to bank A according to control-bank-cfg, yet led@1 describes bank B... Pavel --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --5I6of5zJg18YgZEa Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAltrS4cACgkQMOfwapXb+vKAfQCfbzUzq5mBZdpRkhc2+SYn/F4W QwQAn0BVsaZHm62DgwAMWR6op3an7cC2 =5n4G -----END PGP SIGNATURE----- --5I6of5zJg18YgZEa--