From patchwork Wed Nov 25 16:53:06 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Maciej Nowak X-Patchwork-Id: 1406164 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.openwrt.org (client-ip=2001:8b0:10b:1231::1; helo=merlin.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=merlin.20170209 header.b=KvwyXLn8; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=aWXuC4Vj; dkim-atps=neutral Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4Ch6mt2zm7z9sSn for ; Thu, 26 Nov 2020 04:09:02 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=U+LNmUJNKd3QRcLURgSURHJNrXToBjB3S4dpLnSHqCs=; b=KvwyXLn8krbqIWqAw2rBMcIgOr JyU+7HYjt5Rg3LbT4e4eJjhl/W1TInpu0uCr51nG7gzcgxY6r7dlFNRLIz6vyGbeRgKvFRk3AePuk 3uolGM4brA0j0zsfvQBaCow11mZSLUVZ1GWWrQp2sKcDQPrkTxtL50gbzwFP0GklJfKRakNCenk3P weCEXcMawxsOOuLYQ8TggcwI6Akt30boDxaNK+QZq3c+JSf1rciLI9Te5EGg2djhtdzDoOok/wWAT NdBaGOeFGo4SviSLzYnMtOr5Y71wweuoH7fORaKJM95vUwysO8Fqf/wL82aVkmz3kCLZ/0nfDq+YK JJ48+UaQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1khyGB-00005l-Eb; Wed, 25 Nov 2020 17:07:15 +0000 Received: from mail-lf1-x12c.google.com ([2a00:1450:4864:20::12c]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1khy2g-0001JB-Tn for openwrt-devel@lists.openwrt.org; Wed, 25 Nov 2020 16:53:20 +0000 Received: by mail-lf1-x12c.google.com with SMTP id s27so4079290lfp.5 for ; Wed, 25 Nov 2020 08:53:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lpoe1iPxhislvNeVvkRgLRHo9LIl+B2nxce9gVLcE60=; b=aWXuC4VjD8D5VtKllp/YBlq+rT/DI1ckzBnfTaW2Wgzo406o13c0MIanK8EhgGkTHj 32yJDY3jUjWXGBlHqMCSN38LBDppKfVjBEyzlScumZapuxobxO3yTC+W9taN/X7G3+Sh mKP9uSH0RrF9crejHuXEIyuZM2EC9IxyDg+kJimw5w7Pt/0QGxSZevaYPB9LRjEA+Fmm eSdCnQLLKDjm7dkQe9I6vgCikWoj3TpyZEwJd4cXiJaMs7sX+DzAnnUesnWsngSZGop8 O1Cx7sXkLHU1YtoOrj2g/67qS8vA2adL5PJYBhU6kMPF1KyMbSCEZXwtJzvQTCG2SEkD vJ8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lpoe1iPxhislvNeVvkRgLRHo9LIl+B2nxce9gVLcE60=; b=jh8EL3fjJk3F4wORK0FdI1ALCmFt75/Fs1lYMTEIlSyV/FZfTiXkEHrel7xSd0pI5W mabZI7rIVG0ULZVhxSDqZkS/Zwr8+K/mcSeHiVvgk7BKnI6hJSKvr71sfXfsX5PQBX7S gbJDgkRXnge2rMbRdL8yJkZX9sVW+t/RPU65snR2Mbnj8zsDRy2NoazYApPXbo6+3Nhi GVwO5z2mI9HNczOOl1g47lTu8ltPoP7wOaghemnm+J0s2kHrPtDqRROXV9o4caONxs+z BpYtYYbrJAw+Y4Y/VGXKS4BN5ZVLr0+T3Vsf5MejUmbv2jEk4EeTntGe8+pXG5MgP+2c gCpg== X-Gm-Message-State: AOAM532JYgr1MQol2/1Ey6FKFqqm1KTmXV7NOSJVIFke2wGhoS66ugHu /ojOUhY0sQoRL69Z8fGterBFxFcsgadlrg== X-Google-Smtp-Source: ABdhPJzM8rXGrje6F+dBJA2x0rmua4s0bPLDbUVo+F9mNGPKJ9JhaYmYDntFNHkOW4TkVOdaWwQAvA== X-Received: by 2002:a19:ad42:: with SMTP id s2mr1689987lfd.428.1606323196609; Wed, 25 Nov 2020 08:53:16 -0800 (PST) Received: from localhost.localdomain ([194.29.183.4]) by smtp.googlemail.com with ESMTPSA id c23sm301925ljd.33.2020.11.25.08.53.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Nov 2020 08:53:15 -0800 (PST) From: Tomasz Maciej Nowak To: openwrt-devel@lists.openwrt.org Subject: [PATCH] mvebu: macchiatobin-singleshot: enable heartbeat LED Date: Wed, 25 Nov 2020 17:53:06 +0100 Message-Id: <20201125165306.3060-1-tmn505@gmail.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201125_115319_112260_5B286F13 X-CRM114-Status: GOOD ( 16.15 ) X-Spam-Score: 0.1 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:12c listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [tmn505[at]gmail.com] 0.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends in digit [tmn505[at]gmail.com] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alexandra Alth Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org With board revision 1.3, SolidRun moved the power LED to the middle of the board. In old place of power LED a GPIO controllable heartbeat LED was added. This commit touches only Single Shot variant, because all have revision 1.3. Some boards could be placed in an enclosure, therefore the LED0 is enabled by default, since that'll be the only visible indicator that the board is operating. Ref: http://wiki.macchiatobin.net/tiki-index.php?page=Schematics#Revision1.3_Electrical_Design_Changes Ref: http://macchiatobin.net/wp-content/uploads/2017/11/MACCHIATOBin-rev-1_3.pdf Reported-by: Alexandra Alth Signed-off-by: Tomasz Maciej Nowak --- target/linux/mvebu/image/cortexa72.mk | 2 +- ...s-mcbin-singleshot-add-heartbeat-LED.patch | 59 +++++++++++++++++++ 2 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 target/linux/mvebu/patches-5.4/100-arm64-dts-mcbin-singleshot-add-heartbeat-LED.patch diff --git a/target/linux/mvebu/image/cortexa72.mk b/target/linux/mvebu/image/cortexa72.mk index 1440c07a0b5f..8bd4581766c2 100644 --- a/target/linux/mvebu/image/cortexa72.mk +++ b/target/linux/mvebu/image/cortexa72.mk @@ -38,7 +38,7 @@ define Device/marvell_macchiatobin-singleshot DEVICE_ALT0_VENDOR := SolidRun DEVICE_ALT0_MODEL := Armada 8040 Community Board DEVICE_ALT0_VARIANT := Single Shot - DEVICE_PACKAGES += kmod-i2c-mux-pca954x + DEVICE_PACKAGES += kmod-i2c-mux-pca954x kmod-ledtrig-heartbeat DEVICE_DTS := armada-8040-mcbin-singleshot SUPPORTED_DEVICES := marvell,armada8040-mcbin-singleshot endef diff --git a/target/linux/mvebu/patches-5.4/100-arm64-dts-mcbin-singleshot-add-heartbeat-LED.patch b/target/linux/mvebu/patches-5.4/100-arm64-dts-mcbin-singleshot-add-heartbeat-LED.patch new file mode 100644 index 000000000000..a5f37461360b --- /dev/null +++ b/target/linux/mvebu/patches-5.4/100-arm64-dts-mcbin-singleshot-add-heartbeat-LED.patch @@ -0,0 +1,59 @@ +From 310b7883b64993da355ad5cc3e45f515ac2bef2f Mon Sep 17 00:00:00 2001 +From: Tomasz Maciej Nowak +Date: Sat, 17 Oct 2020 16:53:20 +0200 +Subject: [PATCH] arm64: dts: mcbin-singleshot: add heartbeat LED + +With board revision 1.3, SolidRun moved the power LED to the middle of +the board. In old place of power LED a GPIO controllable heartbeat LED +was added. This commit only touches Single Shot variant, since only this +variant is all revision 1.3. + +Reported-by: Alexandra Alth +Signed-off-by: Tomasz Maciej Nowak +--- + .../marvell/armada-8040-mcbin-singleshot.dts | 22 +++++++++++++++++++ + 1 file changed, 22 insertions(+) + +--- a/arch/arm64/boot/dts/marvell/armada-8040-mcbin-singleshot.dts ++++ b/arch/arm64/boot/dts/marvell/armada-8040-mcbin-singleshot.dts +@@ -5,6 +5,8 @@ + * Device Tree file for MACCHIATOBin Armada 8040 community board platform + */ + ++#include ++ + #include "armada-8040-mcbin.dtsi" + + / { +@@ -12,6 +14,20 @@ + compatible = "marvell,armada8040-mcbin-singleshot", + "marvell,armada8040-mcbin", "marvell,armada8040", + "marvell,armada-ap806-quad", "marvell,armada-ap806"; ++ ++ leds { ++ compatible = "gpio-leds"; ++ pinctrl-0 = <&cp0_led18_pins>; ++ pinctrl-names = "default"; ++ ++ led18 { ++ gpios = <&cp0_gpio2 1 GPIO_ACTIVE_LOW>; ++ function = LED_FUNCTION_HEARTBEAT; ++ color = ; ++ linux,default-trigger = "heartbeat"; ++ default-state = "on"; ++ }; ++ }; + }; + + &cp0_eth0 { +@@ -27,3 +43,10 @@ + managed = "in-band-status"; + sfp = <&sfp_eth1>; + }; ++ ++&cp0_pinctrl { ++ cp0_led18_pins: led18-pins { ++ marvell,pins = "mpp33"; ++ marvell,function = "gpio"; ++ }; ++};