From patchwork Tue Aug 2 12:58:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alistair Francis X-Patchwork-Id: 12934629 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 0869CC00140 for ; Tue, 2 Aug 2022 13:00:41 +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: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=x50CfN1BPOg0iRHNq5upWY1mqz2kPx2GBNkFdomBDrY=; b=SLjahiDLy+WNeW PiufJhG3S/Stcrq6bctN2XmDTRxJnsCaOHoSW4rMpp2H3j7tU+pCjcYMZSwlZNJgXfkLYfqdZ0IDh VKPCZu+G28P/7bUsnWfi158HCktpvM9kiL8Hol6V15PAWJjTLyhLwiaACOtvW3YI78M6rogdFMkyT HNQloit+G8NLZl91LozCxZ6eEls50hO3GFPVbFealZaq2NZlQz8ioNnD0KTNvgi60C6AsXyROUvvg G17jtfo4/am9mVf2V0ef2Gbnq2bXm9huKNL2VRUtCU9nANSVhEGb+rRZ3QMpI8A+iwuKErPZoLuzv +1USVjMRDUtD1bvlKGMA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oIrUl-00EDoi-Vc; Tue, 02 Aug 2022 12:59:36 +0000 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oIrUK-00EDbM-GI for linux-arm-kernel@lists.infradead.org; Tue, 02 Aug 2022 12:59:09 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id AFEF93200926; Tue, 2 Aug 2022 08:59:06 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Tue, 02 Aug 2022 08:59:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alistair23.me; h=cc:cc:content-transfer-encoding:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm3; t=1659445146; x= 1659531546; bh=e69w31e7e/7d0EmO5mFp65sRGccZp1oPXI8E7rKhCCI=; b=i b0G9TFpUlnUivlLX/H0nvNhjUwmj5ByRYpTaJJ53ogvM4cqGg824iutwgbFyzg+O WeK2izewREbl8GIcJvUhyzEDaRimrY+oqV0bLkq2J7yj+tEdZV2A4tXaTCgLPOC0 icgTiBIHGWlYK3uX3Vuz/ShzwBqXO3EL0s5yUpXvdw/1KZiAJxYpf/k+npLrqVw5 RTslqtF2aRabjFHcwBBPk8YWVkhzTp0enNNkiomI9vZcy9vFz7o+uMk8pgTy4Mv1 jR0RvXrA0BTt2i/Ctt8wM8h3cjh5hQfsK5kGJI0P9xpOUA3QlxVA+vnUkitKNutO Riwppm+c7F4Gzi698Nd7w== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; t=1659445146; x=1659531546; bh=e69w31e7e/7d0 EmO5mFp65sRGccZp1oPXI8E7rKhCCI=; b=kOHKeQHicVjPwvvTRROJmlSCmvmJt bMkRqSkhmEFxEGb6ojJm/9l5B8DEXzLwPMqSCu4uFjrvCYx42Awlp33wjjTEap2y vNVp+7kuffVBzJxZyRNRJe/Xoy8qTpAD7A/9P8zlBZEcQmrzw8Sri9432fmOkG3P 1GITupKXm+s2NLifEfJ17Of9gTU3GZdsNAMtsvXdGlHiqPkfmczQviVvca58FdQN S6mL9adhrnIW2z8akucHormKgJe3Hx9pEgI4pfYnrClRCxtnyuCeyiDZkqKyXik1 rOGF+/m8wwWDPjY2c03blLEt54+T/pCYV10yQNU7SjYDXlMB/H+Ko74Zg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvddvhedgheejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucgoufhorhhtvggutfgvtghiphdvucdlgedtmdenuc fjughrpefhvfevufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpeetlhhishht rghirhcuhfhrrghntghishcuoegrlhhishhtrghirhesrghlihhsthgrihhrvdefrdhmvg eqnecuggftrfgrthhtvghrnhepiedtfeekteelvdelveevueeujeffuefguedvteekveej jeeutedufeethffgheehnecuvehluhhsthgvrhfuihiivgepudenucfrrghrrghmpehmrg hilhhfrhhomheprghlihhsthgrihhrsegrlhhishhtrghirhdvfedrmhgv X-ME-Proxy: Feedback-ID: ifd214418:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 2 Aug 2022 08:59:01 -0400 (EDT) From: Alistair Francis To: linux-input@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Cc: shawnguo@kernel.org, alistair23@gmail.com, robh+dt@kernel.org, linus.walleij@linaro.org, s.hauer@pengutronix.de, andreas@kemnade.info, krzysztof.kozlowski+dt@linaro.org, rydberg@bitmath.org, dmitry.torokhov@gmail.com, Alistair Francis Subject: [PATCH v8 4/4] ARM: dts: imx7d-remarkable2: Enable the cyttsp5 Date: Tue, 2 Aug 2022 22:58:27 +1000 Message-Id: <20220802125827.34509-5-alistair@alistair23.me> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220802125827.34509-1-alistair@alistair23.me> References: <20220802125827.34509-1-alistair@alistair23.me> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220802_055908_607205_99E25B24 X-CRM114-Status: UNSURE ( 9.44 ) X-CRM114-Notice: Please train this message. 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 Add support for the cyttsp5 touchscreen controller for the reMarkable 2. Signed-off-by: Alistair Francis --- arch/arm/boot/dts/imx7d-remarkable2.dts | 100 ++++++++++++++++++++++++ 1 file changed, 100 insertions(+) diff --git a/arch/arm/boot/dts/imx7d-remarkable2.dts b/arch/arm/boot/dts/imx7d-remarkable2.dts index a2a91bfdd98e..fea480af8e48 100644 --- a/arch/arm/boot/dts/imx7d-remarkable2.dts +++ b/arch/arm/boot/dts/imx7d-remarkable2.dts @@ -8,6 +8,7 @@ /dts-v1/; #include "imx7d.dtsi" +#include / { model = "reMarkable 2.0"; @@ -47,6 +48,18 @@ reg_digitizer: regulator-digitizer { startup-delay-us = <100000>; /* 100 ms */ }; + reg_touch: regulator-touch { + compatible = "regulator-fixed"; + regulator-name = "VDD_3V3_TOUCH"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&pinctrl_touch_reg>; + pinctrl-1 = <&pinctrl_touch_reg>; + gpio = <&gpio1 11 GPIO_ACTIVE_HIGH>; + enable-active-high; + }; + wifi_pwrseq: wifi_pwrseq { compatible = "mmc-pwrseq-simple"; pinctrl-names = "default"; @@ -84,6 +97,70 @@ wacom_digitizer: digitizer@9 { }; }; +&i2c3 { + clock-frequency = <100000>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_i2c3>; + status = "okay"; + + tsc@24 { + #address-cells = <1>; + #size-cells = <0>; + + compatible = "cypress,tt21000"; + reg = <0x24>; + + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_touch>; + interrupt-parent = <&gpio1>; + interrupts = <14 IRQ_TYPE_EDGE_FALLING>; + reset-gpios = <&gpio1 13 GPIO_ACTIVE_LOW>; + vdd-supply = <®_touch>; + touchscreen-size-x = <880>; + touchscreen-size-y = <1280>; + + button@0 { + reg = <0>; + linux,keycodes = ; + }; + + button@1 { + reg = <1>; + linux,keycodes = ; + }; + + button@2 { + reg = <2>; + linux,keycodes = ; + }; + + button@3 { + reg = <3>; + linux,keycodes = ; + }; + + button@4 { + reg = <4>; + linux,keycodes = ; + }; + + button@5 { + reg = <5>; + linux,keycodes = ; + }; + + button@6 { + reg = <6>; + linux,keycodes = ; + }; + + button@7 { + reg = <7>; + linux,keycodes = ; + }; + }; +}; + &snvs_pwrkey { status = "okay"; }; @@ -177,6 +254,15 @@ MX7D_PAD_SAI1_TX_BCLK__GPIO6_IO13 0x14 >; }; + pinctrl_touch: touchgrp { + fsl,pins = < + /* CYTTSP interrupt */ + MX7D_PAD_GPIO1_IO14__GPIO1_IO14 0x54 + /* CYTTSP reset */ + MX7D_PAD_GPIO1_IO13__GPIO1_IO13 0x04 + >; + }; + pinctrl_i2c1: i2c1grp { fsl,pins = < MX7D_PAD_I2C1_SDA__I2C1_SDA 0x4000007f @@ -184,6 +270,20 @@ MX7D_PAD_I2C1_SCL__I2C1_SCL 0x4000007f >; }; + pinctrl_i2c3: i2c3grp { + fsl,pins = < + MX7D_PAD_I2C3_SDA__I2C3_SDA 0x4000007f + MX7D_PAD_I2C3_SCL__I2C3_SCL 0x4000007f + >; + }; + + pinctrl_touch_reg: touchreggrp { + fsl,pins = < + /* TOUCH_PWR_EN */ + MX7D_PAD_GPIO1_IO11__GPIO1_IO11 0x14 + >; + }; + pinctrl_uart1: uart1grp { fsl,pins = < MX7D_PAD_UART1_TX_DATA__UART1_DCE_TX 0x79