Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp5199630imu; Tue, 8 Jan 2019 13:19:34 -0800 (PST) X-Google-Smtp-Source: ALg8bN6mGJ1AJp2padxsexr2XwnaKfsQTgbbqXUqo1npcCzIfeD7FT5l6pvTZ18JvOl0waq8r5em X-Received: by 2002:a63:4342:: with SMTP id q63mr2967949pga.63.1546982374062; Tue, 08 Jan 2019 13:19:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546982374; cv=none; d=google.com; s=arc-20160816; b=Vl1rOQjQrHVFHFwSUdS6x7Jkc5cUGRG5eluq0M+0ap4oL3aMm3DUONrCvD92GYVOed AV66Ht6jvCiu88f2owVvMY1LRkEaWP48bWNzn/Y3br5VEsON/gSgeTgZcCPnnWHN39f7 fkCG/sMgATSyj+CJmEgF9ZP6E6kQd5/iE+HogxoOtC7PEUXo11ZfdSKluTzhFU3ZVMPc 0C2kXfTOOCNMyHIZdU7nNIGRPrJOrqmhPyBjCj2K3EI7oRtYPbsFg4D5CKB5WbcX4Db2 IMMXz7JyolT4n7/MwcyZaePy2oFC94cULpzVLwZ81zcuUnMeLrdzQieZf2h41ocT7HlX 7iAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=ffJA1v8eqqAiOla1ZUJvfK0j0opKkLQDfgNuSvF6Syc=; b=g38lWDnEdW57FfUfqTknoIzp9HxNlrMY732JWRA9RTF3cEGqyEwhRi6ef1t85+ghtK GJx5pokkoCMgIVWsGzOG6lHMIuOK9ZgUn1z5QbewuTbQ9vzsatdW/6g7zdY/ox+tsaG4 OxryjQrrN30UfPCYwAuhvxVM8ouT8RpYqldNQ2E8v2tqMvPVX4Mhb4EB1mdZ4HpSBPMA uuOtSNbzGXvUen5Ohscrc8wZkcMXuw58zqHQZ9MiEOo8Zdm2rE2m2Npb14dORRY6vt7L ZbOZgsDnt6Cb/abX8ngJWPxl07DJ505mHgBhPM3N4BMu35vXHeKPiziVv7iMrGAPGhdG iuzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=qGsSvTBK; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m3si52039029pgs.8.2019.01.08.13.19.07; Tue, 08 Jan 2019 13:19:34 -0800 (PST) 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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=qGsSvTBK; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729825AbfAHVQ4 (ORCPT + 99 others); Tue, 8 Jan 2019 16:16:56 -0500 Received: from mail-lj1-f194.google.com ([209.85.208.194]:43397 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729493AbfAHVQ4 (ORCPT ); Tue, 8 Jan 2019 16:16:56 -0500 Received: by mail-lj1-f194.google.com with SMTP id q2-v6so4644875lji.10; Tue, 08 Jan 2019 13:16:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ffJA1v8eqqAiOla1ZUJvfK0j0opKkLQDfgNuSvF6Syc=; b=qGsSvTBKLSAfIumtgdwAgQWYF1ycQgcNi1inWn41zbCrl0plvnwxzZxtR6MJz8QgOj 9HgxziD3aggXUdsVuXn6rO4E/7Riu32iHUcpL3gTFWCRwfCQv/snnFeNncZQHPauTOO5 DZ4kCr7YRbi3RCqFD/V3IN6gF3nGdwb72W7bifVKLYSkGbqRWC1R/+GwnjEi8zP7ID3q xdkbfkh2YXsaWNb2/PXql38cjDb3KCG6Db7/fL/SpECV/0nv+TMG/Xe2Um/yJgy4uWXV odjwVV8ya8bo9JPnoQ/+OR2Aq/4xV5BO00qW4Iz4zOgeQg38MoRzSTOfPlg2mUZaC4i7 eUjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ffJA1v8eqqAiOla1ZUJvfK0j0opKkLQDfgNuSvF6Syc=; b=lQVpcG71MCfGa1o7XWilJrn+LW9F3HtSI9Ehirvyz7f5DxDsMnRa7sHkjUZKfcd5ck Gd4QPV8E0VnBFXeypZms34VXEGF3GHRtD6Cef1szzQfgJLbpAqDFU2tiJa3ktvBXbKZQ vyhuYGLv9cdYDxs0nJAKWgbk/sHeHsGZgJVliZUWHbVgMFaOX6aLnFIcX+ee4qMEeUOq GqbQXRS9/MNkDzQBKSlvtDseUciKxFhTpmxHKz5rJdKWFeLvcfbwD7Wk6RN9Ra3X0STy J43q5CgYTX1KhAd2l4oaKozLiRy/yfwNYETh5ai64/blYY6+Xms3E01PpTYVv0xaWtvF q2sg== X-Gm-Message-State: AJcUukenfimJWwXxwD/k8v8EgneAOfYw68KcnpMRFz+MsF7B++/vxMoe axazGKiSbESrhkMiHpnlpGEwQE8K X-Received: by 2002:a2e:612:: with SMTP id 18-v6mr1892244ljg.125.1546982211642; Tue, 08 Jan 2019 13:16:51 -0800 (PST) Received: from [192.168.1.18] (dlx201.neoplus.adsl.tpnet.pl. [83.24.53.201]) by smtp.gmail.com with ESMTPSA id 185-v6sm11840516ljj.49.2019.01.08.13.16.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 08 Jan 2019 13:16:51 -0800 (PST) Subject: Re: [PATCH 1/2] dt: bindings: lp5024: Introduce the lp5024 and lp5018 RGB driver To: Dan Murphy , robh+dt@kernel.org, pavel@ucw.cz Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org References: <20181219162626.12297-1-dmurphy@ti.com> <20181219162626.12297-2-dmurphy@ti.com> <2d2d5dcd-9c23-e901-daac-9b79aa5a5e82@ti.com> From: Jacek Anaszewski Message-ID: <6c62956e-7789-58ba-5437-f2e033f2825c@gmail.com> Date: Tue, 8 Jan 2019 22:16:48 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 MIME-Version: 1.0 In-Reply-To: <2d2d5dcd-9c23-e901-daac-9b79aa5a5e82@ti.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/8/19 9:53 PM, Dan Murphy wrote: > Jacek > > On 1/8/19 2:33 PM, Jacek Anaszewski wrote: >> Dan, >> >> On 12/19/18 5:26 PM, Dan Murphy wrote: >>> Introduce the bindings for the Texas Instruments LP5024 and the LP5018 >>> RGB LED device driver.  The LP5024/18 can control RGB LEDs individually >>> or as part of a control bank group.  These devices have the ability >>> to adjust the mixing control for the RGB LEDs to obtain different colors >>> independent of the overall brightness of the LED grouping. >>> >>> Datasheet: >>> http://www.ti.com/lit/ds/symlink/lp5024.pdf >>> >>> Signed-off-by: Dan Murphy >>> --- >>>   .../devicetree/bindings/leds/leds-lp5024.txt  | 63 +++++++++++++++++++ >>>   1 file changed, 63 insertions(+) >>>   create mode 100644 Documentation/devicetree/bindings/leds/leds-lp5024.txt >>> >>> diff --git a/Documentation/devicetree/bindings/leds/leds-lp5024.txt b/Documentation/devicetree/bindings/leds/leds-lp5024.txt >>> new file mode 100644 >>> index 000000000000..9567aa6f7813 >>> --- /dev/null >>> +++ b/Documentation/devicetree/bindings/leds/leds-lp5024.txt >>> @@ -0,0 +1,63 @@ >>> +* Texas Instruments - LP5024/18 RGB LED driver >>> + >>> +The LM3692x is an ultra-compact, highly efficient, >>> +white-LED driver designed for LCD display backlighting. >>> + >>> +The main difference between the LP5024 and L5018 is the number of >>> +RGB LEDs they support.  The LP5024 supports twenty four strings while the >>> +LP5018 supports eighteen strings. >>> + >>> +Required properties: >>> +    - compatible: >>> +        "ti,lp5018" >>> +        "ti,lp5024" >>> +    - reg :  I2C slave address >>> +    - #address-cells : 1 >>> +    - #size-cells : 0 >>> + >>> +Optional properties: >>> +    - enable-gpios : gpio pin to enable/disable the device. >>> +    - vled-supply : LED supply >>> + >>> +Required child properties: >>> +    - reg : Is the child node iteration. >>> +    - led-sources : LP5024 - 0 - 7 >>> +            LP5018 - 0 - 5 >>> +            Declares the LED string or strings that the child node >>> +            will control.  If ti,control-bank is set then this >>> +            property will contain multiple LED IDs. >>> + >>> +Optional child properties: >>> +    - label : see Documentation/devicetree/bindings/leds/common.txt >>> +    - linux,default-trigger : >>> +       see Documentation/devicetree/bindings/leds/common.txt >>> +    - ti,control-bank : Indicates that the LED strings declared in the >>> +                led-sources property are grouped within a control >>> +                bank for brightness and mixing control. >>> + >>> +Example: >>> + >>> +led-controller@28 { >>> +    compatible = "ti,lp5024"; >>> +    reg = <0x28>; >>> +    #address-cells = <1>; >>> +    #size-cells = <0>; >>> + >>> +    enable-gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>; >>> +    vled-supply = <&vbatt>; >>> + >>> +    led@0 { >>> +        reg = <0>; >>> +        led-sources = <1>; >>> +    }; >>> + >>> +    led@1 { >>> +        reg = <1>; >>> +        led-sources = <0 6>; >>> +        ti,control-bank; >> >> Do you really need ti,control-bank? Doesn't led-sources array size >> greater than 1 mean that the node describes control bank? >> > > That will work too. >> Also, does it make sense to have only two LEDs in the bank? > > The array can populate all 7 LEDs in a single node. I only show 2 here as the example. > See the description above of the led-sources OK, I confused RGB LED modules with banks. Shouldn't we allow for defining either strings or RGB LED triplets somehow then? -- Best regards, Jacek Anaszewski