From patchwork Mon Nov 22 21:36:37 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Jernej_=C5=A0krabec?= X-Patchwork-Id: 12693363 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C9943C433EF for ; Mon, 22 Nov 2021 21:38:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :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=+3ucQKuCubAg8c2BN4X0iyVWzzoXYK2Jumi/B0+kHtA=; b=VtOWgysB+yA1k/ pgZ762pOeLUdQqCTyGoGwlVAPbdHYVo5UPIoZp9vDOb2qrdKPndjniDeZiRHL9ZTFXWshcnPsZ4JZ 1DHdkSVNvuY3woQD3z82xQVlfhTr4tg5I6HjLn7h7j7nLvWTAceRYZUJIFFYk0LXeGkaHm7rdLtK4 JSIeXfZvZerFqHYKtW4VvLNW3BuGiJlr6ZDGIqqMRNI6WA7qeiQ8SF1axBthBN/Ju7CtjQuKnwqx1 1vng0lSeAUvcCcbxYiIGr1f+czrduemtnmpKs8m6i3rSZAXi7NOcpkXRD7X08fIC47D7vyXeKOi3T JyuUcs4euwjYMROZA2Ug==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mpGzV-0003M3-6y; Mon, 22 Nov 2021 21:36:45 +0000 Received: from mail-ed1-x533.google.com ([2a00:1450:4864:20::533]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mpGzR-0003KS-5e for linux-arm-kernel@lists.infradead.org; Mon, 22 Nov 2021 21:36:42 +0000 Received: by mail-ed1-x533.google.com with SMTP id y13so82801816edd.13 for ; Mon, 22 Nov 2021 13:36:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Q52PugtsKbScXR0iC8aYXJ5jdQzIRNmws2e/xLc2+d8=; b=QGXnMVLI1HX+npMNJ5a50sE3Id5ih1HlSqJEcC3++rEek+BuOlIGjlYTRRL4pcwytS wL0gNSUKM5boQlnZzDsNFLAgg3s7CJgB+G7+hJL818C1vv5JAfT9WE/em9vDhW0HRUN8 /OT0uAH6qmOrdY+G3KnOa/kvz5Ixs31CdRR7rvg51atrZVc+fvIi1SkLQBqsCVqNffCD zFQI5Lh2TmuLRzSNvUjtF0B2RyZlLJBXar6S8971/QS4lcTUrr3nmuTX6ZTcUJTZUZ6m +y1uZwQg/35qxdpj0Oo55PQZ2CYiwMtzBE1vpkytzKNyImKjF8WNYglBwkLKt2Bn2ZIt SKRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Q52PugtsKbScXR0iC8aYXJ5jdQzIRNmws2e/xLc2+d8=; b=4l23aqIJ+LYuXz7XEBC3LbRi5YTMamMKFLEC0EOlBJLivfVP14jgVP2gzc0WrclY2Y dae0gNLMewjfBeVQADfNQCJpiWGwnlECKkuEl8eah13YHdZImgsp1NxIpgc6U+TFrB6q mWuQ11JZPuuWG18yEIBeV4V7jUy/WxF10WWhW22NGuOUSaFXchwIYVHJQIFAF7Gi+AJn 8+0dcvSE/HKOQBQwEhPlWVFi2PtwxeEZ/shb5MtCmC/8Z9yg/NE4grN4yyKw20D74DPM 1wf/z91Qbf3+HKElf3B8ZZQp1X1OQi0NwcuahJ1gEvieY9vM7KhMVpGT5gawWmEeq1pO o7Qg== X-Gm-Message-State: AOAM532of653aV9y2c7PM6aRiGUPWp5d6POcDW2hfbfvyImoiGAeyIUy iaoj8R4bLlB0cHOTRkDyVTQ= X-Google-Smtp-Source: ABdhPJxCei9Z/kUcXQS/BMjoGAvP2+xkL3NLG58gfVZf6B7Q7DxrQB9mOwPFvkjzlD9mpqLXdK/X7g== X-Received: by 2002:aa7:c5c4:: with SMTP id h4mr364536eds.386.1637616999810; Mon, 22 Nov 2021 13:36:39 -0800 (PST) Received: from kista.localdomain (cpe-86-58-29-253.static.triera.net. [86.58.29.253]) by smtp.gmail.com with ESMTPSA id v3sm4926458edc.69.2021.11.22.13.36.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Nov 2021 13:36:39 -0800 (PST) From: Jernej Skrabec To: mripard@kernel.org, wens@csie.org Cc: robh+dt@kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, Jernej Skrabec , Michael Klein Subject: [PATCH] ARM: dts: sun8i: Adjust power key nodes Date: Mon, 22 Nov 2021 22:36:37 +0100 Message-Id: <20211122213637.922088-1-jernej.skrabec@gmail.com> X-Mailer: git-send-email 2.34.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211122_133641_233306_79C57E9A X-CRM114-Status: GOOD ( 11.45 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Several H3 and one H2+ board have power key nodes, which are slightly off. Some are missing wakeup-source property and some have BTN_0 code assigned instead of KEY_POWER. Adjust them, so they can function as intended by designer. Signed-off-by: Jernej Skrabec [BananaPi M2 Zero changes] Signed-off-by: Michael Klein --- arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts | 3 ++- arch/arm/boot/dts/sun8i-h3-nanopi.dtsi | 1 + arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 3 ++- arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 3 ++- arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi | 3 ++- arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi | 1 + 6 files changed, 10 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts index 8e8634ff2f9d..d5c7b7984d85 100644 --- a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts +++ b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts @@ -52,8 +52,9 @@ gpio_keys { sw4 { label = "power"; - linux,code = ; + linux,code = ; gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>; + wakeup-source; }; }; diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi index c7c3e7d8b3c8..fc45d5aaa67f 100644 --- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi +++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi @@ -81,6 +81,7 @@ k1 { label = "k1"; linux,code = ; gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>; + wakeup-source; }; }; }; diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts index 597c425d08ec..9daffd90c12f 100644 --- a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts @@ -99,8 +99,9 @@ sw2 { sw4 { label = "sw4"; - linux,code = ; + linux,code = ; gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>; + wakeup-source; }; }; diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts index 5aff8ecc66cb..90f75fa85e68 100644 --- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts @@ -91,8 +91,9 @@ r_gpio_keys { sw4 { label = "sw4"; - linux,code = ; + linux,code = ; gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>; + wakeup-source; }; }; }; diff --git a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi index 7a6af54dd342..d03f5853ef7b 100644 --- a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi +++ b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi @@ -82,8 +82,9 @@ gpio_keys { sw4 { label = "power"; - linux,code = ; + linux,code = ; gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>; + wakeup-source; }; }; diff --git a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi index c44fd726945a..9e14fe5fdcde 100644 --- a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi +++ b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi @@ -49,6 +49,7 @@ power { label = "power"; linux,code = ; gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */ + wakeup-source; }; };