Message ID | 20231021005100.3490929-1-kieran.bingham@ideasonboard.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ce89:0:b0:403:3b70:6f57 with SMTP id p9csp57367vqx; Fri, 20 Oct 2023 17:51:46 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHtS/yMVP+B8JOz18ZEy4QmJcoeWCXXvEhoSr1izFUZkxPTvqtuOcmm3r/gduTKkJGTIYAz X-Received: by 2002:a05:6830:719c:b0:6c6:3926:8055 with SMTP id el28-20020a056830719c00b006c639268055mr3975419otb.6.1697849505688; Fri, 20 Oct 2023 17:51:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697849505; cv=none; d=google.com; s=arc-20160816; b=IunahQI9ICc8JpL3FEzUVY3d2TfkIXW2nbuZ6MkQcpN/VsQiuqeNe9779Yzsb8IY+3 yx1/KiEjP9e9hPbyzREXXySnhh87fHrDtXXJ3FVZgU7XIJdtvvmp7I6LPyTIYcNdaTDO 1KvAGzUCZ9vzC7cm34488rXj2y1SzjwYKCs391meIUhhkUmJCWcFbLNm1iKIrhqNb9Q3 Ru2DHW3M39l5x9OTpncfmeUPhkLuoi8w/QLn7ODzS/yghrgcKEngP0ClFZ3aLc3rbdC8 3dUNysWLFyIDHUKpU5mDk+YPmw9aiCCpQTNVVGiKZtSAXrcp2jk1ztuDqDZ6j/7CDm5W K3vw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=8Ts00Xy4jP/jm2HyZTjkNH1HwCh7ZZU+kZvWUPkO+dY=; fh=CjGHHJS7Xwta/v8XfBHl3aBiTLARQUdtL2FB9VDlKCA=; b=vxGhPXAzP7Zhoe8O3r+Y1h/LYI6+FD7YuMQ9Uib4ZNw6iA6sNY3Oq1zmC7FIvx3P2B D31UDpB2YThALbcoRHYGs6DQzOlmNxO1LeXWujfojRmk/OmBMICWAPDWPq7rOwJjH3Mp mqOh+5GY/WqQd1YbB++BsWQOT6cAI9czoWXGeVBnjQt5dkJA226AT20FDgNIai0fYyUi eyt1wLyObvP4sia4CIaD4FCeUCh7S/njZkr3QiDv40DlLXxPkEkIFHEFvjrTKQ13yMni gSw7Ncvs6OdxbdNTNrWpPLLtquPekB9to88ZXiCXzeEhjBnFb7qGMSNwM6EOPZH4t5zm 3rsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=sQA8jRi7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id b2-20020a056a00114200b0068e380c3654si2797759pfm.395.2023.10.20.17.51.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Oct 2023 17:51:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=sQA8jRi7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id A3DDE83B00B9; Fri, 20 Oct 2023 17:51:39 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229772AbjJUAvO (ORCPT <rfc822;a1648639935@gmail.com> + 26 others); Fri, 20 Oct 2023 20:51:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46442 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229518AbjJUAvN (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 20 Oct 2023 20:51:13 -0400 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5F90BD45; Fri, 20 Oct 2023 17:51:07 -0700 (PDT) Received: from Monstersaurus.local (aztw-30-b2-v4wan-166917-cust845.vm26.cable.virginm.net [82.37.23.78]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D70C43D9; Sat, 21 Oct 2023 02:50:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1697849456; bh=PBZkbLPzXA8ZR2+yr0ypy7V0JDV4Heum3bqNkAxE9/8=; h=From:To:Cc:Subject:Date:From; b=sQA8jRi7RfrE9/aJrisrJXhGjQtKc6e0WjLPQqgsN2bMO+atTjEbkv/VpF0zVbu3H rzNpTZd/eWK5F+g3VP8/ifrPWQNUNjwsand4u0r/JlpTXeG9vF1iH/Tzb+2R02S5Lb oh0BX0a3UTzucs1X9yqptgQBDYsPupMam/g+xw3s= From: Kieran Bingham <kieran.bingham@ideasonboard.com> To: devicetree@vger.kernel.org Cc: Kieran Bingham <kieran.bingham@ideasonboard.com>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Shawn Guo <shawnguo@kernel.org>, Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix Kernel Team <kernel@pengutronix.de>, Fabio Estevam <festevam@gmail.com>, NXP Linux Team <linux-imx@nxp.com>, Marco Felsch <m.felsch@pengutronix.de>, linux-arm-kernel@lists.infradead.org (moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE), linux-kernel@vger.kernel.org (open list) Subject: [PATCH] arm64: dts: freescale: debix-som: Add heartbeat LED Date: Sat, 21 Oct 2023 01:50:58 +0100 Message-Id: <20231021005100.3490929-1-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Fri, 20 Oct 2023 17:51:39 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1780324242898322233 X-GMAIL-MSGID: 1780324242898322233 |
Series |
arm64: dts: freescale: debix-som: Add heartbeat LED
|
|
Commit Message
Kieran Bingham
Oct. 21, 2023, 12:50 a.m. UTC
Map the 'RUN' LED present on the Debix-SOM as a heartbeat.
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
---
.../dts/freescale/imx8mp-debix-som-a.dtsi | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
Comments
Hi Kieran, On 23-10-21, Kieran Bingham wrote: > Map the 'RUN' LED present on the Debix-SOM as a heartbeat. > > Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > --- > .../dts/freescale/imx8mp-debix-som-a.dtsi | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > > diff --git a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > index bc312aa1bfc8..c9a81486da48 100644 > --- a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > +++ b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > @@ -20,6 +20,19 @@ reg_usdhc2_vmmc: regulator-usdhc2 { > gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>; > enable-active-high; > }; > + > + gpio-leds { > + compatible = "gpio-leds"; > + pinctrl-names = "default"; > + pinctrl-0 = <&pinctrl_gpio_led>; > + > + status { according the bindings-doc, this should be: 'led-status' or 'led-0' > + label = "yellow:status"; label is deprecated, instead function and color should be used. With that fixed feel to add my: Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> > + gpios = <&gpio3 16 GPIO_ACTIVE_HIGH>; > + default-state = "on"; > + linux,default-trigger = "heartbeat"; > + }; > + }; > }; > > &A53_0 { > @@ -203,6 +216,12 @@ &wdog1 { > }; > > &iomuxc { > + pinctrl_gpio_led: gpioledgrp { > + fsl,pins = < > + MX8MP_IOMUXC_NAND_READY_B__GPIO3_IO16 0x19 > + >; > + }; > + > pinctrl_i2c1: i2c1grp { > fsl,pins = < > MX8MP_IOMUXC_I2C1_SCL__I2C1_SCL 0x400001c2 > -- > 2.34.1 > >
Hi Marco, Quoting Marco Felsch (2023-10-21 15:08:02) > Hi Kieran, > > On 23-10-21, Kieran Bingham wrote: > > Map the 'RUN' LED present on the Debix-SOM as a heartbeat. > > > > Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > > --- > > .../dts/freescale/imx8mp-debix-som-a.dtsi | 19 +++++++++++++++++++ > > 1 file changed, 19 insertions(+) > > > > diff --git a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > > index bc312aa1bfc8..c9a81486da48 100644 > > --- a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > > +++ b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > > @@ -20,6 +20,19 @@ reg_usdhc2_vmmc: regulator-usdhc2 { > > gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>; > > enable-active-high; > > }; > > + > > + gpio-leds { > > + compatible = "gpio-leds"; > > + pinctrl-names = "default"; > > + pinctrl-0 = <&pinctrl_gpio_led>; > > + > > + status { > > according the bindings-doc, this should be: > > 'led-status' or 'led-0' Interesting - I can see 'led-0' is supported, but I can't see if led-status is supported. Documentation/devicetree/bindings/leds/leds-gpio.yaml: patternProperties: # The first form is preferred, but fall back to just 'led' anywhere in the # node name to at least catch some child nodes. "(^led-[0-9a-f]$|led)": type: object $ref: common.yaml# unevaluatedProperties: false That regex looks like it wouldn't support 'led-status'. Otherwise I'd probably label it as 'led-run' to match how the LED is physically labelled. I've set led-0 locally for now. > > > + label = "yellow:status"; > > label is deprecated, instead function and color should be used. Ohh - I knew that, and I should have remembered this from the last time I did an LED. That was too long ago and too small a task I guess. Looking more closely, the LED is green - not yellow too! so I've udpated this with: led-0 { gpios = <&gpio3 16 GPIO_ACTIVE_HIGH>; default-state = "on"; linux,default-trigger = "heartbeat"; function = LED_FUNCTION_STATUS; color = <LED_COLOR_ID_GREEN>; }; Updating, for a v2. > With that fixed feel to add my: > > Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Thanks. -- Kieran > > > + gpios = <&gpio3 16 GPIO_ACTIVE_HIGH>; > > + default-state = "on"; > > + linux,default-trigger = "heartbeat"; > > + }; > > + }; > > }; > > > > &A53_0 { > > @@ -203,6 +216,12 @@ &wdog1 { > > }; > > > > &iomuxc { > > + pinctrl_gpio_led: gpioledgrp { > > + fsl,pins = < > > + MX8MP_IOMUXC_NAND_READY_B__GPIO3_IO16 0x19 > > + >; > > + }; > > + > > pinctrl_i2c1: i2c1grp { > > fsl,pins = < > > MX8MP_IOMUXC_I2C1_SCL__I2C1_SCL 0x400001c2 > > -- > > 2.34.1 > > > >
On 21/10/2023 02:50, Kieran Bingham wrote: > Map the 'RUN' LED present on the Debix-SOM as a heartbeat. > > Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > --- > .../dts/freescale/imx8mp-debix-som-a.dtsi | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > > diff --git a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > index bc312aa1bfc8..c9a81486da48 100644 > --- a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > +++ b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi > @@ -20,6 +20,19 @@ reg_usdhc2_vmmc: regulator-usdhc2 { > gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>; > enable-active-high; > }; > + > + gpio-leds { > + compatible = "gpio-leds"; > + pinctrl-names = "default"; > + pinctrl-0 = <&pinctrl_gpio_led>; > + > + status { Missing led prefix. I think I fixed it everywhere some time ago, so I wonder from where did you copy it. :/ It does not look like you tested the DTS against bindings. Please run `make dtbs_check W=1` (see Documentation/devicetree/bindings/writing-schema.rst or https://www.linaro.org/blog/tips-and-tricks-for-validating-devicetree-sources-with-the-devicetree-schema/ for instructions). > + label = "yellow:status"; Drop label. Use color and function. Best regards, Krzysztof
diff --git a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi index bc312aa1bfc8..c9a81486da48 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mp-debix-som-a.dtsi @@ -20,6 +20,19 @@ reg_usdhc2_vmmc: regulator-usdhc2 { gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>; enable-active-high; }; + + gpio-leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_gpio_led>; + + status { + label = "yellow:status"; + gpios = <&gpio3 16 GPIO_ACTIVE_HIGH>; + default-state = "on"; + linux,default-trigger = "heartbeat"; + }; + }; }; &A53_0 { @@ -203,6 +216,12 @@ &wdog1 { }; &iomuxc { + pinctrl_gpio_led: gpioledgrp { + fsl,pins = < + MX8MP_IOMUXC_NAND_READY_B__GPIO3_IO16 0x19 + >; + }; + pinctrl_i2c1: i2c1grp { fsl,pins = < MX8MP_IOMUXC_I2C1_SCL__I2C1_SCL 0x400001c2