From patchwork Tue Dec 22 15:13:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kepplinger X-Patchwork-Id: 1356064 Return-Path: Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DBCAEC433E9 for ; Tue, 22 Dec 2020 15:14:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 983FD23133 for ; Tue, 22 Dec 2020 15:14:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727837AbgLVPOq (ORCPT ); Tue, 22 Dec 2020 10:14:46 -0500 Received: from comms.puri.sm ([159.203.221.185]:54808 "EHLO comms.puri.sm" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726868AbgLVPOp (ORCPT ); Tue, 22 Dec 2020 10:14:45 -0500 Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id 6660BE0212; Tue, 22 Dec 2020 07:14:05 -0800 (PST) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id rh01BL-ncLL3; Tue, 22 Dec 2020 07:14:04 -0800 (PST) From: Martin Kepplinger To: robh@kernel.org, shawnguo@kernel.org, festevam@gmail.com Cc: kernel@pengutronix.de, linux-imx@nxp.com, krzk@kernel.org, kernel@puri.sm, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Kepplinger Subject: [PATCH v2 1/4] arm64: dts: imx8mq-librem5: add vin-supply to VDD_1V8 Date: Tue, 22 Dec 2020 16:13:44 +0100 Message-Id: <20201222151347.7886-2-martin.kepplinger@puri.sm> In-Reply-To: <20201222151347.7886-1-martin.kepplinger@puri.sm> References: <20201222151347.7886-1-martin.kepplinger@puri.sm> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org buck7 is the supply here. Also, fix alphabetical ordering. Signed-off-by: Martin Kepplinger --- arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi index 64fc546b110f..55268fc0622e 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi @@ -99,6 +99,14 @@ regulator-max-microvolt = <3300000>; }; + reg_vdd_1v8: regulator-vdd-1v8 { + compatible = "regulator-fixed"; + regulator-name = "VDD_1V8"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + vin-supply = <&buck7_reg>; + }; + reg_vdd_3v3: regulator-vdd-3v3 { compatible = "regulator-fixed"; regulator-name = "VDD_3V3"; @@ -106,13 +114,6 @@ regulator-max-microvolt = <3300000>; }; - reg_vdd_1v8: regulator-vdd-1v8 { - compatible = "regulator-fixed"; - regulator-name = "VCC_1V8"; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - }; - reg_vsys_3v4: regulator-vsys-3v4 { compatible = "regulator-fixed"; regulator-name = "VSYS_3V4"; From patchwork Tue Dec 22 15:13:45 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kepplinger X-Patchwork-Id: 1356063 Return-Path: Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 10BC1C43381 for ; Tue, 22 Dec 2020 15:14:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DEF442336D for ; Tue, 22 Dec 2020 15:14:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727914AbgLVPOu (ORCPT ); Tue, 22 Dec 2020 10:14:50 -0500 Received: from comms.puri.sm ([159.203.221.185]:54828 "EHLO comms.puri.sm" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727840AbgLVPOu (ORCPT ); Tue, 22 Dec 2020 10:14:50 -0500 Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id 03B7DE021B; Tue, 22 Dec 2020 07:14:10 -0800 (PST) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wiO2Ga4tHL6U; Tue, 22 Dec 2020 07:14:09 -0800 (PST) From: Martin Kepplinger To: robh@kernel.org, shawnguo@kernel.org, festevam@gmail.com Cc: kernel@pengutronix.de, linux-imx@nxp.com, krzk@kernel.org, kernel@puri.sm, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Kepplinger Subject: [PATCH v2 2/4] arm64: dts: imx8mq-librem5: add pinctrl for the touchscreen description Date: Tue, 22 Dec 2020 16:13:45 +0100 Message-Id: <20201222151347.7886-3-martin.kepplinger@puri.sm> In-Reply-To: <20201222151347.7886-1-martin.kepplinger@puri.sm> References: <20201222151347.7886-1-martin.kepplinger@puri.sm> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In order for the touchscreen interrupt line to work, describe it properly. Otherwise it can work if defaults are ok, but we cannot be sure. Fixes: 8f0216b006e5 ("arm64: dts: Add a device tree for the Librem 5 phone") Signed-off-by: Martin Kepplinger Reviewed-by: Krzysztof Kozlowski --- arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi index 55268fc0622e..a60df09d90f7 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi @@ -459,6 +459,13 @@ >; }; + pinctrl_touch: touchgrp { + fsl,pins = < + /* TP_INT */ + MX8MQ_IOMUXC_ENET_RD1_GPIO1_IO27 0x80 + >; + }; + pinctrl_typec: typecgrp { fsl,pins = < /* TYPEC_MUX_EN */ @@ -880,6 +887,8 @@ touchscreen@38 { compatible = "edt,edt-ft5506"; reg = <0x38>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_touch>; interrupt-parent = <&gpio1>; interrupts = <27 IRQ_TYPE_EDGE_FALLING>; touchscreen-size-x = <720>; From patchwork Tue Dec 22 15:13:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kepplinger X-Patchwork-Id: 1356066 Return-Path: Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2B5A7C433DB for ; Tue, 22 Dec 2020 15:15:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 07DC823159 for ; Tue, 22 Dec 2020 15:15:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727994AbgLVPPY (ORCPT ); Tue, 22 Dec 2020 10:15:24 -0500 Received: from comms.puri.sm ([159.203.221.185]:54904 "EHLO comms.puri.sm" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727950AbgLVPPY (ORCPT ); Tue, 22 Dec 2020 10:15:24 -0500 Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id BC582E0244; Tue, 22 Dec 2020 07:14:13 -0800 (PST) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PYB_3EtSZIaq; Tue, 22 Dec 2020 07:14:13 -0800 (PST) From: Martin Kepplinger To: robh@kernel.org, shawnguo@kernel.org, festevam@gmail.com Cc: kernel@pengutronix.de, linux-imx@nxp.com, krzk@kernel.org, kernel@puri.sm, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Kepplinger Subject: [PATCH v2 3/4] arm64: dts: imx8mq-librem5: Move usdhc clocks assignment to board DT Date: Tue, 22 Dec 2020 16:13:46 +0100 Message-Id: <20201222151347.7886-4-martin.kepplinger@puri.sm> In-Reply-To: <20201222151347.7886-1-martin.kepplinger@puri.sm> References: <20201222151347.7886-1-martin.kepplinger@puri.sm> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org According to commit e045f044e84e ("arm64: dts: imx8mq: Move usdhc clocks assignment to board DT") add the clocks assignment to imx8mq-librem5.dtsi too. Fixes: e045f044e84e ("arm64: dts: imx8mq: Move usdhc clocks assignment to board DT") Signed-off-by: Martin Kepplinger Reviewed-by: Krzysztof Kozlowski --- arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi index a60df09d90f7..47e70ba4e4f1 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi @@ -1082,6 +1082,8 @@ }; &usdhc1 { + assigned-clocks = <&clk IMX8MQ_CLK_USDHC1>; + assigned-clock-rates = <400000000>; pinctrl-names = "default", "state_100mhz", "state_200mhz"; pinctrl-0 = <&pinctrl_usdhc1>; pinctrl-1 = <&pinctrl_usdhc1_100mhz>; @@ -1094,6 +1096,8 @@ }; &usdhc2 { + assigned-clocks = <&clk IMX8MQ_CLK_USDHC2>; + assigned-clock-rates = <200000000>; pinctrl-names = "default", "state_100mhz", "state_200mhz"; pinctrl-0 = <&pinctrl_usdhc2>; pinctrl-1 = <&pinctrl_usdhc2_100mhz>; From patchwork Tue Dec 22 15:13:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kepplinger X-Patchwork-Id: 1356065 Return-Path: Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 45FB6C433DB for ; Tue, 22 Dec 2020 15:15:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1BEEF230FC for ; Tue, 22 Dec 2020 15:15:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727943AbgLVPO7 (ORCPT ); Tue, 22 Dec 2020 10:14:59 -0500 Received: from comms.puri.sm ([159.203.221.185]:54882 "EHLO comms.puri.sm" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727499AbgLVPO6 (ORCPT ); Tue, 22 Dec 2020 10:14:58 -0500 Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id 4D616DF318; Tue, 22 Dec 2020 07:14:18 -0800 (PST) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6fDrWgpGall8; Tue, 22 Dec 2020 07:14:17 -0800 (PST) From: Martin Kepplinger To: robh@kernel.org, shawnguo@kernel.org, festevam@gmail.com Cc: kernel@pengutronix.de, linux-imx@nxp.com, krzk@kernel.org, kernel@puri.sm, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Kepplinger Subject: [PATCH v2 4/4] arm64: dts: imx8mq-librem5-r3: workaround i2c1 issue with 1GHz cpu voltage Date: Tue, 22 Dec 2020 16:13:47 +0100 Message-Id: <20201222151347.7886-5-martin.kepplinger@puri.sm> In-Reply-To: <20201222151347.7886-1-martin.kepplinger@puri.sm> References: <20201222151347.7886-1-martin.kepplinger@puri.sm> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is a workaround for a hardware bug in the r3 revision that basically would stop the system due to traffic on the i2c1 bus. A cpu voltage change would trigger such traffic and that's what is avoided in order to work around it. Signed-off-by: Martin Kepplinger --- arch/arm64/boot/dts/freescale/imx8mq-librem5-r3.dts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5-r3.dts b/arch/arm64/boot/dts/freescale/imx8mq-librem5-r3.dts index 6704ea2c72a3..0d38327043f8 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5-r3.dts +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5-r3.dts @@ -10,6 +10,12 @@ compatible = "purism,librem5r3", "purism,librem5", "fsl,imx8mq"; }; +&a53_opp_table { + opp-1000000000 { + opp-microvolt = <1000000>; + }; +}; + &accel_gyro { mount-matrix = "1", "0", "0", "0", "1", "0",