Message ID | 20230122-msm8974-bacon-features-v1-5-4049f565c24c@z3ntu.xyz |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp1232292wrn; Sun, 22 Jan 2023 09:07:46 -0800 (PST) X-Google-Smtp-Source: AMrXdXsBzPzgGqoVz0c1hM75zcsq7gWnVuqYDMxirLVeCZCKike8wiPCoenUhJxvyMAqlBsh1R1i X-Received: by 2002:a17:907:8b87:b0:877:91b2:b11a with SMTP id tb7-20020a1709078b8700b0087791b2b11amr10611382ejc.76.1674407266262; Sun, 22 Jan 2023 09:07:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674407266; cv=none; d=google.com; s=arc-20160816; b=xOsjobXqX4BHoB2TsbfnV17dL3WZF199wiS/0e0VRfGHFB4fxZOjiCPwmBf67EkZTP dRiMNuWXEsi1TBtjNmViYQhQU9UlpzN+003h9mtQGx6/oJCS7iVPC041oKw8rY62MSig RtgwT92QvT3PtjEyZMY0U5Mjo8MeCVGSnDyFIsyLtMBn7l1V8YlHYRmvNFlRMcwT6blg vGqXVW1flGML4O9l6TBjn9odvVb5+/6MJzM192t4RmyaOAVoDLvi2UjpRq4sJzuPE0Ds jvDaf9kiFs26RNzIngE2C9FtYSIk2Lk0zJMvnJ5tQ5px292l0rxm1glp1xPK0QmPuvAR /Q+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=foOr8bwKMgPvFq9lsN9LW/0jKYs307hdASgSTfrk3kQ=; b=R3aj0n3lqh5lF2e27/kHr/k0S32tCflop7LSGtKLwGMUxhBvf9/TahFy8Hp6XNKAHv lduHE6bjPGfjUSJXulrpeYFsT81HPRG3X5Yib7Ie1DxribFMidCO2idp1XpZsCkTUg5C 2lPw2STIU2/SboI3QDw6jqll5V9Wd626CdvPn7HkGmXLKB9bX1ty2cGh7HLMiaNNvtrF VsFiN9ZPSixA9QMqFWqJq0/QHkjTBs7Z3fkmixI452xDOuYxWQKih5urWdmU/ZWCCeKl Gh/sbsOD5YoiqMCBaO3qO7hunj0puus/iwhxgr+fCVMeBPMOG4eCkEbVzTdiVxus42VI PQsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@z3ntu.xyz header.s=z3ntu header.b=fVblwWHY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=z3ntu.xyz Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id wv4-20020a170907080400b007c0b52d0df1si50876734ejb.660.2023.01.22.09.07.22; Sun, 22 Jan 2023 09:07:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@z3ntu.xyz header.s=z3ntu header.b=fVblwWHY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=z3ntu.xyz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230241AbjAVQtn (ORCPT <rfc822;forouhar.linux@gmail.com> + 99 others); Sun, 22 Jan 2023 11:49:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230037AbjAVQtm (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 22 Jan 2023 11:49:42 -0500 Received: from mail.z3ntu.xyz (mail.z3ntu.xyz [128.199.32.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 78F281C320; Sun, 22 Jan 2023 08:49:32 -0800 (PST) Received: from [192.168.178.23] (unknown [62.108.10.64]) by mail.z3ntu.xyz (Postfix) with ESMTPSA id AE834CD52F; Sun, 22 Jan 2023 16:48:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=z3ntu.xyz; s=z3ntu; t=1674406136; bh=UC4MZp7joZ5KIGVSNAjIE3z+woZwa8RY5kG95For80s=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=fVblwWHYIq+sZjwawB8O/+pjliEqr1MXSpYnZ4VYptxGu/htsKJQYy3mvkJNPL/Re qnJC9+OEUQ+h0mMU+Rq6PhvP2xrNcbMwYxxWmVbPlrBHPdCOl+2+xU110ZhDqMtN4B hBNLu3aL9/t/mrFmF2DMtf+a7qyhEHH1BaP1wFsc= From: Luca Weiss <luca@z3ntu.xyz> Date: Sun, 22 Jan 2023 17:48:36 +0100 Subject: [PATCH 5/5] ARM: dts: qcom: msm8974-oneplus-bacon: Add notification LED MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230122-msm8974-bacon-features-v1-5-4049f565c24c@z3ntu.xyz> References: <20230122-msm8974-bacon-features-v1-0-4049f565c24c@z3ntu.xyz> In-Reply-To: <20230122-msm8974-bacon-features-v1-0-4049f565c24c@z3ntu.xyz> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Andy Gross <agross@kernel.org>, Bjorn Andersson <andersson@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org> Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss <luca@z3ntu.xyz> X-Mailer: b4 0.11.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1264; i=luca@z3ntu.xyz; h=from:subject:message-id; bh=UC4MZp7joZ5KIGVSNAjIE3z+woZwa8RY5kG95For80s=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBjzWj2Melh4WgPgof4i5KIb9eQCvJo0gQAcgbgA6Ml Zfm8VqOJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCY81o9gAKCRBy2EO4nU3XVrm3EA C/KppKnzqSEjeDp67YBOnF3nRIdl7sMxjYsRfYN0kkt3dOtwmFkhbXoqplheSGGdjdIpOqWWYyu5p5 vbabckzcp6SPm/XhlGBPFtq+diyApCW8CUx6JzsS0LhLEVrJpHH5+0gJeRaPQc/rVq8r+wld8x4y+h pT0kpn/f3SDYycRw0QwvY6poLHZxu6/BUx54rrKS5klUOuwUatphUBLHO2F9ms0EO5VHsHcoKj4e1S rwygzJH1uQnRN4Na6SK6VO9uO9aXcwd4tFqw1Fhrq2KVvpJvN/TmIaxfZBp5OcLEOiUWsYZzDzr8ud ie2j811S73Bs3yZdmGfkJUilDHOjJoQyqAcDQBQORrQ5EdldgFuEVHgxfRev8FMCgoMQTFIWunbq0u VM7ENcBQ7tBDlX95Ne7tMEUdMXsM/2obbPKYDKJRQ/4cJWbAlfSAVGIZP/TVPq6q+Yj6Bfnz8jcPyH 3Hva2cUGoMKhrGv93G5Tolj7NLnNnF3JB2Aq9L2HZlZZhuvdBK/uETx96gAmpA/TBpp8HrM9iJZ5WU La9QVrfGOcypa7xbAFB/Ut49xBt3dfuQxRBwh7ppTrR8xRYf8OslVNoJNBnf/+TBQ01AmMF34JImMO 8yDLkg4icyACHND+hdUkb2f6K6q0Q9mdcYQYnSnD44tTAsc0z81scOnc8ytw== X-Developer-Key: i=luca@z3ntu.xyz; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FROM_SUSPICIOUS_NTLD,SPF_HELO_NONE,SPF_PASS, T_PDS_OTHER_BAD_TLD,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1755743273442632152?= X-GMAIL-MSGID: =?utf-8?q?1755743273442632152?= |
Series |
Add support for some features on OnePlus One
|
|
Commit Message
Luca Weiss
Jan. 22, 2023, 4:48 p.m. UTC
Add the node describing the sn3193 that's used to provide notification
LED.
Unfortunately the driver currently supports neither multicolor API nor
using the properties function & color, so we use label instead.
Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
---
.../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 ++++++++++++++++++++++
1 file changed, 28 insertions(+)
Comments
On 22.01.2023 17:48, Luca Weiss wrote: > Add the node describing the sn3193 that's used to provide notification > LED. > > Unfortunately the driver currently supports neither multicolor API nor > using the properties function & color, so we use label instead. > > Signed-off-by: Luca Weiss <luca@z3ntu.xyz> > --- Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org> Konrad > .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 ++++++++++++++++++++++ > 1 file changed, 28 insertions(+) > > diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > index ffb486ceb6a6..a672c45d7070 100644 > --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > @@ -114,6 +114,34 @@ led@0 { > default-brightness = <80>; > }; > }; > + > + led-controller@68 { > + compatible = "si-en,sn3193"; > + reg = <0x68>; > + > + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; > + > + #address-cells = <1>; > + #size-cells = <0>; > + > + led@1 { > + reg = <1>; > + label = "red:status"; > + led-max-microamp = <17500>; > + }; > + > + led@2 { > + reg = <2>; > + label = "green:status"; > + led-max-microamp = <17500>; > + }; > + > + led@3 { > + reg = <3>; > + label = "blue:status"; > + led-max-microamp = <17500>; > + }; > + }; > }; > > &blsp1_i2c6 { >
On 22/01/2023 17:48, Luca Weiss wrote: > Add the node describing the sn3193 that's used to provide notification > LED. > > Unfortunately the driver currently supports neither multicolor API nor > using the properties function & color, so we use label instead. > > Signed-off-by: Luca Weiss <luca@z3ntu.xyz> > --- > .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 ++++++++++++++++++++++ > 1 file changed, 28 insertions(+) > > diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > index ffb486ceb6a6..a672c45d7070 100644 > --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > @@ -114,6 +114,34 @@ led@0 { > default-brightness = <80>; > }; > }; > + > + led-controller@68 { > + compatible = "si-en,sn3193"; > + reg = <0x68>; > + > + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; > + > + #address-cells = <1>; > + #size-cells = <0>; > + > + led@1 { > + reg = <1>; > + label = "red:status"; These should be colors and functions. Best regards, Krzysztof
On Montag, 23. Jänner 2023 18:18:16 CET Krzysztof Kozlowski wrote: > On 22/01/2023 17:48, Luca Weiss wrote: > > Add the node describing the sn3193 that's used to provide notification > > LED. > > > > Unfortunately the driver currently supports neither multicolor API nor > > using the properties function & color, so we use label instead. > > > > Signed-off-by: Luca Weiss <luca@z3ntu.xyz> > > --- > > > > .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 > > ++++++++++++++++++++++ 1 file changed, 28 insertions(+) > > > > diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts index > > ffb486ceb6a6..a672c45d7070 100644 > > --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > @@ -114,6 +114,34 @@ led@0 { > > > > default-brightness = <80>; > > > > }; > > > > }; > > > > + > > + led-controller@68 { > > + compatible = "si-en,sn3193"; > > + reg = <0x68>; > > + > > + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; > > + > > + #address-cells = <1>; > > + #size-cells = <0>; > > + > > + led@1 { > > + reg = <1>; > > + label = "red:status"; > > These should be colors and functions. Hi Krzysztof, please check the commit message for this. I tried using it but it didn't work, the driver in general might need an overhaul at some point... > Unfortunately the driver currently supports neither multicolor API nor > using the properties function & color, so we use label instead. Or maybe I messed up but pretty sure this was the case when I wrote the dts. Regards Luca > > > Best regards, > Krzysztof
On 25/01/2023 21:51, Luca Weiss wrote: > On Montag, 23. Jänner 2023 18:18:16 CET Krzysztof Kozlowski wrote: >> On 22/01/2023 17:48, Luca Weiss wrote: >>> Add the node describing the sn3193 that's used to provide notification >>> LED. >>> >>> Unfortunately the driver currently supports neither multicolor API nor >>> using the properties function & color, so we use label instead. >>> >>> Signed-off-by: Luca Weiss <luca@z3ntu.xyz> >>> --- >>> >>> .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 >>> ++++++++++++++++++++++ 1 file changed, 28 insertions(+) >>> >>> diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>> b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts index >>> ffb486ceb6a6..a672c45d7070 100644 >>> --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>> +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>> @@ -114,6 +114,34 @@ led@0 { >>> >>> default-brightness = <80>; >>> >>> }; >>> >>> }; >>> >>> + >>> + led-controller@68 { >>> + compatible = "si-en,sn3193"; >>> + reg = <0x68>; >>> + >>> + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; >>> + >>> + #address-cells = <1>; >>> + #size-cells = <0>; >>> + >>> + led@1 { >>> + reg = <1>; >>> + label = "red:status"; >> >> These should be colors and functions. > > Hi Krzysztof, > > please check the commit message for this. I tried using it but it didn't work, > the driver in general might need an overhaul at some point... > >> Unfortunately the driver currently supports neither multicolor API nor >> using the properties function & color, so we use label instead. > > Or maybe I messed up but pretty sure this was the case when I wrote the dts. I don't understand how driver is related here - it's not the driver's property, but LED core. If the driver "supports" label, then it supports color and status. Best regards, Krzysztof
On Donnerstag, 26. Jänner 2023 10:41:24 CET Krzysztof Kozlowski wrote: > On 25/01/2023 21:51, Luca Weiss wrote: > > On Montag, 23. Jänner 2023 18:18:16 CET Krzysztof Kozlowski wrote: > >> On 22/01/2023 17:48, Luca Weiss wrote: > >>> Add the node describing the sn3193 that's used to provide notification > >>> LED. > >>> > >>> Unfortunately the driver currently supports neither multicolor API nor > >>> using the properties function & color, so we use label instead. > >>> > >>> Signed-off-by: Luca Weiss <luca@z3ntu.xyz> > >>> --- > >>> > >>> .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 > >>> ++++++++++++++++++++++ 1 file changed, 28 insertions(+) > >>> > >>> diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > >>> b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts index > >>> ffb486ceb6a6..a672c45d7070 100644 > >>> --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > >>> +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > >>> @@ -114,6 +114,34 @@ led@0 { > >>> > >>> default-brightness = <80>; > >>> > >>> }; > >>> > >>> }; > >>> > >>> + > >>> + led-controller@68 { > >>> + compatible = "si-en,sn3193"; > >>> + reg = <0x68>; > >>> + > >>> + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; > >>> + > >>> + #address-cells = <1>; > >>> + #size-cells = <0>; > >>> + > >>> + led@1 { > >>> + reg = <1>; > >>> + label = "red:status"; > >> > >> These should be colors and functions. > > > > Hi Krzysztof, > > > > please check the commit message for this. I tried using it but it didn't > > work, the driver in general might need an overhaul at some point... > > > >> Unfortunately the driver currently supports neither multicolor API nor > >> using the properties function & color, so we use label instead. > > > > Or maybe I messed up but pretty sure this was the case when I wrote the > > dts. > I don't understand how driver is related here - it's not the driver's > property, but LED core. If the driver "supports" label, then it supports > color and status. The leds-is31fl319x.c driver uses devm_led_classdev_register but the function where 'function' and 'color' is parsed is led_parse_fwnode_props which is called from led_compose_name which is called from led_classdev_register_ext (or with the devm_ prefix), and not called from the register method without _ext suffix. So in other words, the led driver would need changes to use the new registration API to be able to use 'function' and 'color' instead of 'label'. Regards Luca > > Best regards, > Krzysztof
On 26/01/2023 21:41, Luca Weiss wrote: > On Donnerstag, 26. Jänner 2023 10:41:24 CET Krzysztof Kozlowski wrote: >> On 25/01/2023 21:51, Luca Weiss wrote: >>> On Montag, 23. Jänner 2023 18:18:16 CET Krzysztof Kozlowski wrote: >>>> On 22/01/2023 17:48, Luca Weiss wrote: >>>>> Add the node describing the sn3193 that's used to provide notification >>>>> LED. >>>>> >>>>> Unfortunately the driver currently supports neither multicolor API nor >>>>> using the properties function & color, so we use label instead. >>>>> >>>>> Signed-off-by: Luca Weiss <luca@z3ntu.xyz> >>>>> --- >>>>> >>>>> .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 >>>>> ++++++++++++++++++++++ 1 file changed, 28 insertions(+) >>>>> >>>>> diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>>>> b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts index >>>>> ffb486ceb6a6..a672c45d7070 100644 >>>>> --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>>>> +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts >>>>> @@ -114,6 +114,34 @@ led@0 { >>>>> >>>>> default-brightness = <80>; >>>>> >>>>> }; >>>>> >>>>> }; >>>>> >>>>> + >>>>> + led-controller@68 { >>>>> + compatible = "si-en,sn3193"; >>>>> + reg = <0x68>; >>>>> + >>>>> + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; >>>>> + >>>>> + #address-cells = <1>; >>>>> + #size-cells = <0>; >>>>> + >>>>> + led@1 { >>>>> + reg = <1>; >>>>> + label = "red:status"; >>>> >>>> These should be colors and functions. >>> >>> Hi Krzysztof, >>> >>> please check the commit message for this. I tried using it but it didn't >>> work, the driver in general might need an overhaul at some point... >>> >>>> Unfortunately the driver currently supports neither multicolor API nor >>>> using the properties function & color, so we use label instead. >>> >>> Or maybe I messed up but pretty sure this was the case when I wrote the >>> dts. >> I don't understand how driver is related here - it's not the driver's >> property, but LED core. If the driver "supports" label, then it supports >> color and status. > > The leds-is31fl319x.c driver uses devm_led_classdev_register but the function > where 'function' and 'color' is parsed is led_parse_fwnode_props which is > called from led_compose_name which is called from led_classdev_register_ext > (or with the devm_ prefix), and not called from the register method without > _ext suffix. No, devm_led_classdev_register calls devm_led_classdev_register_ext which calls led_classdev_register_ext which calls led_compose_name (if initdata is set). The point is that we lack initdata, so indeed color and function cannot be used. > > So in other words, the led driver would need changes to use the new > registration API to be able to use 'function' and 'color' instead of 'label'. > > Regards > Luca > >> >> Best regards, >> Krzysztof > > > > Best regards, Krzysztof
Hi! > > Unfortunately the driver currently supports neither multicolor API nor > > using the properties function & color, so we use label instead. > > > > Signed-off-by: Luca Weiss <luca@z3ntu.xyz> > > --- > > .../arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts | 28 ++++++++++++++++++++++ > > 1 file changed, 28 insertions(+) > > > > diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > index ffb486ceb6a6..a672c45d7070 100644 > > --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts > > @@ -114,6 +114,34 @@ led@0 { > > default-brightness = <80>; > > }; > > }; > > + > > + led-controller@68 { > > + compatible = "si-en,sn3193"; > > + reg = <0x68>; > > + > > + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; > > + > > + #address-cells = <1>; > > + #size-cells = <0>; > > + > > + led@1 { > > + reg = <1>; > > + label = "red:status"; > > These should be colors and functions. Yep. Plus this is one LED, not three, so it should use the multicolor class. And then we should have an entry in Documentation/leds/well-known-leds.txt so that we have same ABI on all the phones. Best regards, Pavel
diff --git a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts index ffb486ceb6a6..a672c45d7070 100644 --- a/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts +++ b/arch/arm/boot/dts/qcom-msm8974pro-oneplus-bacon.dts @@ -114,6 +114,34 @@ led@0 { default-brightness = <80>; }; }; + + led-controller@68 { + compatible = "si-en,sn3193"; + reg = <0x68>; + + shutdown-gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; + + #address-cells = <1>; + #size-cells = <0>; + + led@1 { + reg = <1>; + label = "red:status"; + led-max-microamp = <17500>; + }; + + led@2 { + reg = <2>; + label = "green:status"; + led-max-microamp = <17500>; + }; + + led@3 { + reg = <3>; + label = "blue:status"; + led-max-microamp = <17500>; + }; + }; }; &blsp1_i2c6 {