From patchwork Wed May 26 10:54:08 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Niedermaier X-Patchwork-Id: 12281775 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E9AA6C47082 for ; Wed, 26 May 2021 14:03:28 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id A9C4C613C9 for ; Wed, 26 May 2021 14:03:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A9C4C613C9 Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=dh-electronics.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org 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:References:In-Reply-To: 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: List-Owner; bh=iptRalCHAz8Rd3Jt5OkisPQ53C9aL72Y1LK5tKD6jSY=; b=fNv+D7wCg77x3p +rzW8tzZfRoEASSYlg9euWhtxN/2LTR+vrig8bEml/MPBg6TFEQCuq2vw6gbTuuWAITjZJpRG/Q/t wWEzCG1/M7nDA8Xcvsy//NnlfATfez2+oyTstgBUtJl/Ip7tr2pn7O0LyomAPfqwDja/xBqR8t2Jn +HzR0YcCboyifItMZYZ4OTwjK+C8TN6hl134/wS5/1Ly/2TqB8ZqjegGpTXj3QJAm7l5HxWxLX1DH S9+Ihcd4h6efbvWDsavsadOTZJS257PC0J+cOrIQ7pqWjS6rpXhp2NePXQvh177gHiWBO8K3QxBZL YTigTJJEqvQjj1t9iiCA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1llu4l-00EfGT-54; Wed, 26 May 2021 14:00:00 +0000 Received: from mx4.securetransport.de ([178.254.6.145]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1llsOs-00DrlV-Rt for linux-arm-kernel@lists.infradead.org; Wed, 26 May 2021 12:12:40 +0000 Received: from mail.dh-electronics.com (business-24-134-97-169.pool2.vodafone-ip.de [24.134.97.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx4.securetransport.de (Postfix) with ESMTPSA id 04D6C7201F3; Wed, 26 May 2021 14:11:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dh-electronics.com; s=dhelectronicscom; t=1622031118; bh=s9K2X4ZrEEjhmu3ewt4LRr44McU3vI0kBhWbJUDAis4=; h=From:To:CC:Subject:Date:In-Reply-To:References:From; b=PBQhq4Y/6Cd+NKYU/iFsybFYukKJOu7f7H6UmwAcUCEjIPLgrXHgnPE5iFRjIRW4A qm/TX2ujKfg+dOrT+7qlmL4GVHaxguG4FuhRVsQzUx+WD/isustgt9CFZCU80ZPJ9B kKLP8BkhKZ5x7qsaZWB64jI8k/bHmhGQHtRxV0J4C6eV2zFlqvG5hcSjebuT5bfNHO 8bQJeuw7ZS0CFWeNiQn0+WSPbGCXqdqnEL1JUI3rMTZNtVOtxVHOfQhlQ4+PAl/4wV 2Jc7XI85kOABb9Z3I3m2iWc15FFdsI+7QHaJVmoNr5VwyoTVPzlHexaIsPJGynwKqt Ph5xwBuocxk1Q== Received: from DHPWEX01.DH-ELECTRONICS.ORG (2001:470:76a7:2::30) by DHPWEX01.DH-ELECTRONICS.ORG (2001:470:76a7:2::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.858.12; Wed, 26 May 2021 12:56:27 +0200 Received: from localhost.localdomain (172.16.51.17) by DHPWEX01.DH-ELECTRONICS.ORG (10.64.2.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.858.12 via Frontend Transport; Wed, 26 May 2021 12:56:26 +0200 From: Christoph Niedermaier To: CC: Christoph Niedermaier , Shawn Guo , Fabio Estevam , Marek Vasut , NXP Linux Team , Subject: [PATCH 11/20] ARM: dts: imx6q-dhcom: Add keys and leds to the PDK2 board Date: Wed, 26 May 2021 12:54:08 +0200 Message-ID: <20210526105417.52996-12-cniedermaier@dh-electronics.com> X-Mailer: git-send-email 2.11.0 X-klartext: yes In-Reply-To: <20210526105417.52996-1-cniedermaier@dh-electronics.com> References: <20210526105417.52996-1-cniedermaier@dh-electronics.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210526_051239_107727_4A4F58FD X-CRM114-Status: GOOD ( 14.63 ) 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 On the PDK2 there are 4 keys and 4 leds. DHCOM GPIOs are used for that, but one led isn't useable, because the GPIO is already use as touch interrupt. Signed-off-by: Christoph Niedermaier Cc: Shawn Guo Cc: Fabio Estevam Cc: Marek Vasut Cc: NXP Linux Team Cc: kernel@dh-electronics.com To: linux-arm-kernel@lists.infradead.org --- arch/arm/boot/dts/imx6q-dhcom-pdk2.dts | 88 ++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) diff --git a/arch/arm/boot/dts/imx6q-dhcom-pdk2.dts b/arch/arm/boot/dts/imx6q-dhcom-pdk2.dts index 6bb7129d0498..fd29128d8602 100644 --- a/arch/arm/boot/dts/imx6q-dhcom-pdk2.dts +++ b/arch/arm/boot/dts/imx6q-dhcom-pdk2.dts @@ -57,6 +57,76 @@ }; }; + gpio-keys { + #size-cells = <0>; + compatible = "gpio-keys"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_keys_pdk2>; + + button-0 { + label = "TA1-GPIO-A"; + linux,code = ; + gpios = <&gpio1 2 GPIO_ACTIVE_LOW>; + wakeup-source; + }; + + button-1 { + label = "TA2-GPIO-B"; + linux,code = ; + gpios = <&gpio1 4 GPIO_ACTIVE_LOW>; + wakeup-source; + }; + + button-2 { + label = "TA3-GPIO-C"; + linux,code = ; + gpios = <&gpio1 5 GPIO_ACTIVE_LOW>; + wakeup-source; + }; + + button-3 { + label = "TA4-GPIO-D"; + linux,code = ; + gpios = <&gpio6 3 GPIO_ACTIVE_LOW>; + wakeup-source; + }; + }; + + led { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_leds_pdk2>; + + /* + * Disable led5, because GPIO E is + * already used as touch interrupt. + */ + led-0 { + label = "green:led5"; + gpios = <&gpio4 5 GPIO_ACTIVE_HIGH>; /* GPIO E */ + default-state = "off"; + status = "disabled"; + }; + + led-1 { + label = "green:led6"; + gpios = <&gpio4 20 GPIO_ACTIVE_HIGH>; /* GPIO F */ + default-state = "off"; + }; + + led-2 { + label = "green:led7"; + gpios = <&gpio4 7 GPIO_ACTIVE_HIGH>; /* GPIO H */ + default-state = "off"; + }; + + led-3 { + label = "green:led8"; + gpios = <&gpio4 8 GPIO_ACTIVE_HIGH>; /* GPIO I */ + default-state = "off"; + }; + }; + panel { compatible = "edt,etm0700g0edh6"; ddc-i2c-bus = <&i2c2>; @@ -237,6 +307,24 @@ MX6QDL_PAD_NANDF_CS1__GPIO6_IO14 0x120b0 >; }; + + pinctrl_keys_pdk2: keys-pdk2-grp { + fsl,pins = < + MX6QDL_PAD_GPIO_2__GPIO1_IO02 0x120b0 /* TA1 */ + MX6QDL_PAD_GPIO_4__GPIO1_IO04 0x120b0 /* TA2 */ + MX6QDL_PAD_GPIO_5__GPIO1_IO05 0x120b0 /* TA3 */ + MX6QDL_PAD_CSI0_DAT17__GPIO6_IO03 0x120b0 /* TA4 */ + >; + }; + + pinctrl_leds_pdk2: leds-pdk2-grp { + fsl,pins = < + MX6QDL_PAD_DI0_PIN4__GPIO4_IO20 0x120b0 /* led6 */ + MX6QDL_PAD_KEY_ROW0__GPIO4_IO07 0x120b0 /* led7 */ + MX6QDL_PAD_KEY_COL1__GPIO4_IO08 0x120b0 /* led8 */ + >; + }; + }; &ipu1_di0_disp0 {