From patchwork Wed Sep 6 10:08:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cem Tenruh X-Patchwork-Id: 13375554 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 9D4F2EB8FAF for ; Wed, 6 Sep 2023 11:16:50 +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=AdnZ1fXIkasQHQLXKjh0jcocx+4usuKWqoeA29s45tI=; b=I6mZ6R30V5H6MM zpDHt1j8Fdshkt5zthzgfC6XaGvZ+KeTXYqVJBornLLuWl/ZlkNVg4y/dAdowEK5VYkJhthpXf6wX 4ujuIbqxVUVFNCo6iBEkKTW5LBt59iq9FLB5n/WvLNmWW4gaH8o4S4wevAABaNDDY94rN9+qWVT4W DdMi2ERw/XDTlmpJpzKsRIl6OV+mvc7jOCIMt3mNXbmp/q7O0VGEsymkR2YceooMPltMEWjwfVBGV w4uA+cuuhmuOBcV84sIrZvlV8PJddrI1+q7YfheD0j340f17JfeSWVU14Q5t2zw2+8c9V1Y/6W7JX HzVAxrGe9J8zeGqAYRsg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qdqWX-008bK2-2B; Wed, 06 Sep 2023 11:16:41 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qdpT9-00854I-1f for linux-arm-kernel@bombadil.infradead.org; Wed, 06 Sep 2023 10:09:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Transfer-Encoding:MIME-Version :References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=pkRAOLlg0xvn9mxcY/ahhX2PQCXOBZpPwvGfkeoF4+Q=; b=ZVeeqr93i0Tc3eFPlRsMik+0XL UAVQV0jN0UfUHlZs2ufHiskRyM1lpbC5jAv2kzzeueK5IGrSyl/klntbuoco6kr+bdRXbEb1efVO2 EvuNSVz+LadBbHMWi/d32g0ghcnAcxguFSNAj7TPORjJ5OtXkSyT/jCaGZMIkNM0L9GDIn9JHZXXT CWcQTY9WMHuq6Jx6/lM7++L282b3JFJGPRWprwShLF2c8ndA9DVQujUqROWk8yVv2NUFSnS+C3jvR jGUZCeOD0Cma1hUKiBmX4lCxEtnaZQqsDyRArur8aKxXOpab2To63hP+vGpJsE40B+UQQAEvkmeK2 1KbMWLxQ==; Received: from mickerik.phytec.de ([91.26.50.163]) by desiato.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qdpT3-0012bY-24 for linux-arm-kernel@lists.infradead.org; Wed, 06 Sep 2023 10:09:05 +0000 DKIM-Signature: v=1; a=rsa-sha256; d=phytec.de; s=a4; c=relaxed/simple; q=dns/txt; i=@phytec.de; t=1693994938; x=1696586938; h=From:Sender:Reply-To:Subject:Date:Message-Id:To:Cc:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=mIYeza+5WyWAvAETAP2fzAbdpn5wPznFZMPx7eSo4kQ=; b=H8mYU5xLUNC0DAZL2J1R8Iu55H7EUkOJmQ8VP9vTk4aHsJ456TqBk2GW6WnlM+yJ Ee1FYIg6Awdoov6E8JGet4S3xI4ZGAu/skq52sOoZ0/aW6vo+EF7SNrQbi/F/0QK c4MxUxsyRLFiBslqMJmH8ectIOAYfpm/PaJwgTnTKrQ=; X-AuditID: ac14000a-6e25770000001e37-c0-64f84fba03c3 Received: from idefix.phytec.de (Unknown_Domain [172.25.0.20]) by mickerik.phytec.de (PHYTEC Mail Gateway) with SMTP id 1B.4D.07735.ABF48F46; Wed, 6 Sep 2023 12:08:58 +0200 (CEST) Received: from llp-ausleih01.fritz.box ([172.25.39.56]) by idefix.phytec.de (IBM Domino Release 9.0.1FP7) with ESMTP id 2023090612085826-11041 ; Wed, 6 Sep 2023 12:08:58 +0200 From: Cem Tenruh To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team Cc: linux-arm-kernel@lists.infradead.org, upstream@lists.phytec.de Subject: [PATCH v4 1/5] arm64: dts: imx8mp-phyboard-pollux: Add flexcan support Date: Wed, 6 Sep 2023 12:08:53 +0200 Message-Id: <20230906100857.7916-2-c.tenruh@phytec.de> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230906100857.7916-1-c.tenruh@phytec.de> References: <20230906100857.7916-1-c.tenruh@phytec.de> MIME-Version: 1.0 X-MIMETrack: Itemize by SMTP Server on Idefix/Phytec(Release 9.0.1FP7|August 17, 2016) at 06.09.2023 12:08:58, Serialize by Router on Idefix/Phytec(Release 9.0.1FP7|August 17, 2016) at 06.09.2023 12:08:58 X-TNEFEvaluated: 1 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrCLMWRmVeSWpSXmKPExsWyRpJBRHeX/48Ug+2nFSzW7D3HZPHwqr/F qqk7WSz6Xjxkttj0+BqrRdevlcwWrXuPsFv83b6JxeLFFnGL7nfqDlweO2fdZffYtKqTzePO tT1sHpuX1Hv0d7ewemx8t4PJo/+vQQB7FJdNSmpOZllqkb5dAlfG2gerWQt2iFf0dvUxNjDu FO5i5OSQEDCROLh5GVMXIxeHkMA2RolDF3ewQDgXGSW2nTzKDlLFJqAqMe/YRGYQW0TgEJPE yitxIDazgJPEx4avLCC2sIC/xIIj7awgNouAisTvyy+YQGxeATOJib8mskJsk5fYf/As2BxO AXOJw9tWsIHYQkA1J+f8ZoWoF5Q4OfMJC0T9FUagBl4IW0ji9GKIXmYBbYllC18zT2AUmIWk ZRaS1AJGplWMQrmZydmpRZnZegUZlSWpyXopqZsYQSEvwsC1g7FvjschRiYOxkOMEhzMSiK8 7+S/pQjxpiRWVqUW5ccXleakFh9ilOZgURLnvd/DlCgkkJ5YkpqdmlqQWgSTZeLglGpgtLOb ULKVW+Tm3V8hMiHxt091iOTptjPbOYkcEuMSfMvUaqFQzGal78j90Gd70hJ5i+POied+7BS4 +nzf/hWGDmJPihgNnp1PTWG+8zVkRmjQF7U1WzlCPz/3n3F107y3upeUtrXb+FVaadTIPp/f Xjax4r7I7qk7EgMn8E35duXZqoO/5vsaKLEUZyQaajEXFScCAMACC5NnAgAA X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230906_110903_359953_84163E51 X-CRM114-Status: GOOD ( 11.35 ) 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 From: Teresa Remmet Add flexcan1 and flexcan2 support for CAN FD on phyBOARD-Pollux. Signed-off-by: Teresa Remmet Signed-off-by: Cem Tenruh Reviewed-by: Fabio Estevam --- Changes in v4: - No changes Changes in v3: - No changes Changes in v2: - No changes --- .../freescale/imx8mp-phyboard-pollux-rdk.dts | 61 +++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mp-phyboard-pollux-rdk.dts b/arch/arm64/boot/dts/freescale/imx8mp-phyboard-pollux-rdk.dts index 1e14c4cd3128..1750fadb64c3 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-phyboard-pollux-rdk.dts +++ b/arch/arm64/boot/dts/freescale/imx8mp-phyboard-pollux-rdk.dts @@ -19,6 +19,26 @@ chosen { stdout-path = &uart1; }; + reg_can1_stby: regulator-can1-stby { + compatible = "regulator-fixed"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_flexcan1_reg>; + gpio = <&gpio3 20 GPIO_ACTIVE_LOW>; + regulator-max-microvolt = <3300000>; + regulator-min-microvolt = <3300000>; + regulator-name = "can1-stby"; + }; + + reg_can2_stby: regulator-can2-stby { + compatible = "regulator-fixed"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_flexcan2_reg>; + gpio = <&gpio3 21 GPIO_ACTIVE_LOW>; + regulator-max-microvolt = <3300000>; + regulator-min-microvolt = <3300000>; + regulator-name = "can2-stby"; + }; + reg_usdhc2_vmmc: regulator-usdhc2 { compatible = "regulator-fixed"; pinctrl-names = "default"; @@ -57,6 +77,21 @@ ethphy0: ethernet-phy@1 { }; }; +/* CAN FD */ +&flexcan1 { + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_flexcan1>; + xceiver-supply = <®_can1_stby>; + status = "okay"; +}; + +&flexcan2 { + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_flexcan2>; + xceiver-supply = <®_can2_stby>; + status = "okay"; +}; + &i2c2 { clock-frequency = <400000>; pinctrl-names = "default", "gpio"; @@ -136,6 +171,32 @@ MX8MP_IOMUXC_SAI1_MCLK__GPIO4_IO20 0x10 >; }; + pinctrl_flexcan1: flexcan1grp { + fsl,pins = < + MX8MP_IOMUXC_SAI5_RXD2__CAN1_RX 0x154 + MX8MP_IOMUXC_SAI5_RXD1__CAN1_TX 0x154 + >; + }; + + pinctrl_flexcan2: flexcan2grp { + fsl,pins = < + MX8MP_IOMUXC_SAI5_MCLK__CAN2_RX 0x154 + MX8MP_IOMUXC_SAI5_RXD3__CAN2_TX 0x154 + >; + }; + + pinctrl_flexcan1_reg: flexcan1reggrp { + fsl,pins = < + MX8MP_IOMUXC_SAI5_RXC__GPIO3_IO20 0x154 + >; + }; + + pinctrl_flexcan2_reg: flexcan2reggrp { + fsl,pins = < + MX8MP_IOMUXC_SAI5_RXD0__GPIO3_IO21 0x154 + >; + }; + pinctrl_i2c2: i2c2grp { fsl,pins = < MX8MP_IOMUXC_I2C2_SCL__I2C2_SCL 0x400001c2