From patchwork Mon Nov 21 13:30:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 23743 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1588712wrr; Mon, 21 Nov 2022 05:32:48 -0800 (PST) X-Google-Smtp-Source: AA0mqf72RFTHekor2Moxa/2KBKKxhuwSX+XYsVTmOJSyfjqT64snlWMcSlEYAqbnXghi7JO2Ei1b X-Received: by 2002:a50:d7de:0:b0:469:61de:adce with SMTP id m30-20020a50d7de000000b0046961deadcemr7497547edj.218.1669037567984; Mon, 21 Nov 2022 05:32:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669037567; cv=none; d=google.com; s=arc-20160816; b=RL/B7wcfNtrqrGwAU2UvxJgniMPujjT+r2DPcbQx3Ajp4KjYk8LV/O1BC72LHAx1LP 42tcArI4fl18l34OB8Pzut4EWshMe/y9EK/XtBP1b3PBgOmqypVNCD1BZbuQtn3wi7qZ zk9uIgEhRoxV1oSavOI6twsNZlG9cQn1thG7FIKNvLMql4c69fcfEnfl6FDC6ntWacwH wWrV9Do4JbfoWnGFFL6mrkvY7jczdNXIFr7MM0PZz1zbQfZEAhUvp00AfVHJqGy9/oqu FGLuTV8K4GAeiMBR/4otmX3XpTsFOkqFDoLrKPgm3WZ4VVrL7u/lu3EmnNxT6Ig8vLkR QlFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :feedback-id:references:in-reply-to:message-id:subject:cc:from:to :dkim-signature:date; bh=mKT0b3j/bY3j0Y2khrfg5ryVKfOy6kNma6mcjHf4UFk=; b=OJadXFlumeUAb7bHuuFtUwGUs+B9TqShZHnlPc6KAcoWMox6F4FL70g/iFRR+cOyoE saRuo32B8Y296+YBvf8asprKJ/j64GEHG0YO2lcFLX+Wg2LPZdYTmq7fdDaR4bHqvPZa v8/89BdkKaNm9gE/RnsGL+mhmBTWVYMXkRsXMcGvGMTTza45ywLwGWz2bkDmoEw3tA9H J5uwSFHtWh90ejsbc9z/evejPXomWgTeANDbzs5PDoyH+msFS2cYyNue+WimQkPibU3m hWIU0hXo5PSNRoglMfw5B8L4ETWcUm8HPi4Fw2NIy4H0ZdhdVI+zl3qYu2Xre7mcC+aD pckQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@protonmail.com header.s=protonmail3 header.b=uxKHFg5q; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id dp17-20020a170906c15100b0078049ab4bbasi9413303ejc.526.2022.11.21.05.32.15; Mon, 21 Nov 2022 05:32:47 -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=pass header.i=@protonmail.com header.s=protonmail3 header.b=uxKHFg5q; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230127AbiKUNak (ORCPT + 99 others); Mon, 21 Nov 2022 08:30:40 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35354 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230333AbiKUNaW (ORCPT ); Mon, 21 Nov 2022 08:30:22 -0500 Received: from mail-4319.protonmail.ch (mail-4319.protonmail.ch [185.70.43.19]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8F49C9CF4D; Mon, 21 Nov 2022 05:30:21 -0800 (PST) Date: Mon, 21 Nov 2022 13:30:08 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1669037419; x=1669296619; bh=mKT0b3j/bY3j0Y2khrfg5ryVKfOy6kNma6mcjHf4UFk=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=uxKHFg5qink059OjMX5SBp5hgDzBD22x0sYk2ao+/WDipzCBmreMpMXqc3q/wJU9t LDU32gPDgQ/4ly/zd7aaiKZKBf24InB/nbig9XfOfbpAULpYEz0OcGHZZy+nfrKKdB lNY9VecwuawXJOPpv+9VGDqUPp1p6xPtDpXWyT0KS1RSL7K/7H/JHiANHc8ztFitEw 7zjeQLuKD06nKaiNKIO24dcZZkxiAI7CWIV8Br3Jy2AXEBiPkkZ5oLXCZN5JHOPG8E bkBRgBmzjxES8FrBYjNBkt0bo+FjXpY+99QY6BPn8sY+/chO8KuJYeva/BSpRudZBw WuHPwZJHVRXVA== To: linux-kernel@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Linus Walleij , Stanislav Jakubek , Shawn Guo , Stephan Gerhold , Nikita Travkin , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: [PATCH v3 5/5] arm64: dts: qcom: msm8916-gplus-fl8005a: Add flash LED Message-ID: <20221121132838.207107-1-linmengbo0689@protonmail.com> In-Reply-To: <20221121132139.206581-1-linmengbo0689@protonmail.com> References: <20221121132139.206581-1-linmengbo0689@protonmail.com> Feedback-ID: 40467236:user:proton MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=unavailable 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750112736368520415?= X-GMAIL-MSGID: =?utf-8?q?1750112736368520415?= FL8005A uses SGM3140 Flash LED driver. Add it to the device tree. Signed-off-by: Lin, Meng-Bo Reviewed-by: Konrad Dybcio --- .../boot/dts/qcom/msm8916-gplus-fl8005a.dts | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts b/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts index 2cac99e3e52c..b28d7d0f1ed5 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts +++ b/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts @@ -21,6 +21,21 @@ chosen { stdout-path = "serial0"; }; + flash-led-controller { + compatible = "sgmicro,sgm3140"; + enable-gpios = <&msmgpio 31 GPIO_ACTIVE_HIGH>; + flash-gpios = <&msmgpio 32 GPIO_ACTIVE_HIGH>; + + pinctrl-names = "default"; + pinctrl-0 = <&camera_flash_default>; + + flash_led: led { + function = LED_FUNCTION_FLASH; + color = ; + flash-max-timeout-us = <250000>; + }; + }; + gpio-keys { compatible = "gpio-keys"; @@ -239,6 +254,14 @@ l18 { }; &msmgpio { + camera_flash_default: camera-flash-default-state { + pins = "gpio31", "gpio32"; + function = "gpio"; + + drive-strength = <2>; + bias-disable; + }; + gpio_keys_default: gpio-keys-default-state { pins = "gpio107"; function = "gpio";