Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp589497pxb; Wed, 27 Jan 2021 16:02:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJyxfhCUkP+hsHteHwutnLM7FwtfqyNYbWtbEx0FJCzCqhCQ5AnkAuQOnLFDrGCwvCvONISS X-Received: by 2002:a17:906:e48:: with SMTP id q8mr8481540eji.478.1611792128357; Wed, 27 Jan 2021 16:02:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611792128; cv=none; d=google.com; s=arc-20160816; b=L2gtgYBGI0BlNr5SgT2P2pCWPP9/6bURXKIXULwfkKiK0l3guW7lBf33Re+tOvpy1Z JVt8tRxNuZUVfAWY0VyGA6cbN/BEZKPn+HhKrSPUi2FSvztTHRcA9Ee+nfr4zc9WcQPz /PJKfdDO5AZQXOcCN6LR01tYVVy0zOErduBnTB4v2YlgpWguGj4bqoDJlCAJG7siqoyO OEa934kfwoCqLNEgcr7/FJ/AqFPxDEsttBPIkCBho1eBzu6P1jcQ+YAfvhUP+3KwaHFO +xHL4AjDP6HjcoPJhVO/5lFAKcwc7GO0FfSnonBuu1Kf18uHkqpkOvinSvhwizPQ+XBh BqNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=AkjKYkZu/O3ZhL9C1ly1S1R+Lu1EqcZrKzNmqSx7LJM=; b=BNXWfjoppvsotKvDd4y76I17edA0REUyV14ZasNvQNbniPtzqSY437E2V4YSDogxQ9 7UNg3bfW2fAWEmzEc1BEQeniF5tJc5mG091BGfTXxeAlhMhiUkMakDdH5OdQx17ctSvM lKt2Qe9il+WPE2YLrvEVUxDZIZGkKyVhdSAG+70gKVMzWngxvWs9Plmczt9+1MVXDxXT wsD1BkzFqIlsUtd7c4yHYgZ2qyOe0XY2EO55p75dfpaEudE7iGSCxc+CbCWQUnaIIhOY GCGmhlPkpaMYO+yOKZnZKPNyN3Y+r/Z/061JtLCh8Y7esapq5OuvGiZ+x/7TR3P/3LNT oTIQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ds5cTovt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a1si1934018edq.48.2021.01.27.16.01.43; Wed, 27 Jan 2021 16:02:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ds5cTovt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233880AbhA0OeN (ORCPT + 99 others); Wed, 27 Jan 2021 09:34:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45152 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234236AbhA0OdL (ORCPT ); Wed, 27 Jan 2021 09:33:11 -0500 Received: from mail-ot1-x331.google.com (mail-ot1-x331.google.com [IPv6:2607:f8b0:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6E921C0613ED for ; Wed, 27 Jan 2021 06:32:31 -0800 (PST) Received: by mail-ot1-x331.google.com with SMTP id i20so1826676otl.7 for ; Wed, 27 Jan 2021 06:32:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=AkjKYkZu/O3ZhL9C1ly1S1R+Lu1EqcZrKzNmqSx7LJM=; b=ds5cTovti/PtWeJ9L9rKyAOoOCJlHao6cqyS9WX5rNXOcqjvrACFYWilYmHuy7YEyU Zr2gd5FdUeJLOW4mz/aprPbp4jYKkyWlUXgrn9h3WYr3u6hB8NAXTQzpnelYnHsugmKZ 8PMgx78aR3uz8ZN6yPR1Fkrs+Kt5ya4IVDz5OvzISuhkLEicnFWhBEqdIXCZprV357r3 980hdxNsheXU0huewLbFRO07m8egm/Zkuhqmd8q/0jApuDMAriwEoDScJaO8OaW6pD60 J9WcOsudPLTYDO1sGadIy6cBl0PLr/9byY+lSqueuNJHlLE2zEF6GcacqQhYJS9jvbWy qo+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=AkjKYkZu/O3ZhL9C1ly1S1R+Lu1EqcZrKzNmqSx7LJM=; b=Yj3G6c1DZBbtv5NlOZenHd7MTDteJ7ArZmxRtmeY2y59jW5Uko6YiTYpZhWFHvi2zR AjLGPr9uhp+3XidnxoP7/4EYq8CR4XLFFAWO4KqMKpegBGPwApm6JVjMQzTKcDymVbit TEo+VocgRNzMVHAXxWSkm/+m3/WQsgXGdrrLkh62o67ySMTNB5OG4r6FRRjWfQe0Qlrr aICL+WaSF3+txSWlx3W0Vixt6x4OePSvl/Uz5yFfAHZI241ua+QySE9kMivzsnBFP0Cb RNI7dcFWP+XtWd7IYcBYk7rbftF/Gz6q2c8UPVIgAAmz9n/y11Fy6SIA/ugd14PDs0tM MZNQ== X-Gm-Message-State: AOAM533uIOzBwprdRwF0N+DPrcm+x/9Y/QuKMA8MKVzLJ8wT2c271Bft Y6irBIJujjT8r+RD5BNBqbpMdQ== X-Received: by 2002:a9d:5cc3:: with SMTP id r3mr8437957oti.286.1611757950813; Wed, 27 Jan 2021 06:32:30 -0800 (PST) Received: from builder.lan (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id o98sm404617ota.0.2021.01.27.06.32.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Jan 2021 06:32:30 -0800 (PST) Date: Wed, 27 Jan 2021 08:32:28 -0600 From: Bjorn Andersson To: "N?colas F. R. A. Prado" Cc: Pavel Machek , Dan Murphy , Andy Gross , Rob Herring , linux-leds@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, Brian Masney , Luca Weiss , Russell King , Georgi Djakov , linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, lkcamp@lists.libreplanetbr.org, andrealmeid@collabora.com Subject: Re: [PATCH v2 4/4] ARM: dts: qcom: pm8941: Add nodes for QCOM SPMI Flash LEDs Message-ID: References: <20210126140240.1517044-1-nfraprado@protonmail.com> <20210126140240.1517044-5-nfraprado@protonmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20210126140240.1517044-5-nfraprado@protonmail.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 26 Jan 08:06 CST 2021, N?colas F. R. A. Prado wrote: > Add the necessary devicetree nodes for the Qualcomm SPMI Flash LEDs > present in PM8941. > > Signed-off-by: N?colas F. R. A. Prado > --- > Changes in v2: > - Moved from hammerhead dts to pm8941 dtsi, as it was this way downstream > - Now using values from leds-qcom-spmi-flash.h > > arch/arm/boot/dts/qcom-pm8941.dtsi | 38 ++++++++++++++++++++++++++++++ > 1 file changed, 38 insertions(+) > > diff --git a/arch/arm/boot/dts/qcom-pm8941.dtsi b/arch/arm/boot/dts/qcom-pm8941.dtsi > index c1f2012d1c8b..89309d3c777c 100644 > --- a/arch/arm/boot/dts/qcom-pm8941.dtsi > +++ b/arch/arm/boot/dts/qcom-pm8941.dtsi > @@ -2,6 +2,8 @@ > #include > #include > #include > +#include > +#include > > &spmi_bus { > > @@ -189,5 +191,41 @@ pm8941_5vs2: 5vs2 { > regulator-initial-mode = <1>; > }; > }; > + > + qcom,spmi-flash@d300 { Please avoid "qcom," in the node names. > + status = "okay"; The "default" status is "okay", so no need to specify that if you're not disabling it. That said, there are 8974 devices without flash LED... > + > + compatible = "qcom,spmi-flash"; > + reg = <0xd300 0x100>; > + flash-boost-supply = <&pm8941_5vs1>; > + torch-boost-supply = <&pm8941_5v>; > + pm8941_flash0: led0 { > + led-sources = <0>; > + function = LED_FUNCTION_FLASH; > + color = ; > + led-max-microamp = <200000>; > + flash-max-microamp = <1000000>; > + flash-max-timeout-us = <1280000>; > + default-state = "off"; > + qcom,clamp-curr = <200000>; > + qcom,headroom = ; > + qcom,startup-dly = ; > + qcom,safety-timer; ...and I would expect that at least some of these properties should be tweaked/tuned/reviewed for each device. So it would probably be a good idea to make the spmi-flash status "disabled" and move some of these properties to the product .dts. Regards, Bjorn > + }; > + > + pm8941_flash1: led1 { > + led-sources = <1>; > + function = LED_FUNCTION_FLASH; > + color = ; > + led-max-microamp = <200000>; > + flash-max-microamp = <1000000>; > + flash-max-timeout-us = <1280000>; > + default-state = "off"; > + qcom,clamp-curr = <200000>; > + qcom,headroom = ; > + qcom,startup-dly = ; > + qcom,safety-timer; > + }; > + }; > }; > }; > -- > 2.30.0 > >