From patchwork Thu Jun 6 18:47:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 13688902 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2059.outbound.protection.outlook.com [40.107.21.59]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5960C198821 for ; Thu, 6 Jun 2024 18:47:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.21.59 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717699662; cv=fail; b=c5s3k9BGVSK5dRdR1AxCW+RWUeE9lSbWuj4TaHB6IxuQr6inmbe2qZwUdZVdOw7mXfyfCC8YVI069DJ+9G/scR5wOpbt/xJ3gAmNfUe7JqwpLDbXcFrDWVd2DcDI830yuAntjSj+XCI1f8/5q8EeRHClkvNj+DG5YQviETt5GOo= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717699662; c=relaxed/simple; bh=V3aSz9OakazJIsc+Ir1XSAlA2aVt7bvWPkO3FQk4jxc=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=dBj8IeeQc3BH6gnXO4Awvjj2VbP9BJZiN/skLIRd9y3ipdfY9dc/yAN/MP56bv9KKeoifcv1e5gFmgjopol/pDvUGQ/Zi/FcjAEBTBCpgptbkTRW2j4hrTgiDsmOoS24WI0n9cUouFRdcd494vtoNx5T5wh5IEcwW847lREgENY= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=TGJrilru; arc=fail smtp.client-ip=40.107.21.59 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="TGJrilru" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=D5XoZKi79zjQht7nHCra1v5aT82o9uHmKeRF84OqR5t0IEME/890/aRn2o5Z9dANfyrI6dLM1kKx49A1PIEE7EZMuq3BIAZEzBFm7RwABQ2najSOlA2936Enhil0FdJtwemV6/Fc3jJMCuyzhhgwLrQMBvP3A21ru2ROPA2U0uLm4CcjnFnZnSB3V5DBBsoH7Lp3OYVsDagSNmRvvRhX9HUBd2Ska6zCognIE6qqJN8fugKMievqh7p+ccydzOs00KF3xrdJEayTFBLVEwdCtPdycLPTiPKYzwywckWlW9OoqBmsypPYbt6aHRdTvxxS/GJezGHmUNNiKKoP2qWusQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=gMiZVQ5uikdAZbdSJmQz0HHKZZOr++Izx2iEEvyXRPs=; b=RquiDWDIN2ZXaSHX+rbugr15NCapiG1Y3dULAIT9wr4pdfewni9/XHM4cZ+/vDN7DSVAOiGH5L4CqvRKoaUhxt2sLVzq2Er3ZCD7j6uuG2rDC4aUWGarj9ZU+By6ajE4ZEImPErYUMu1Q9h3OHYXId15OuwiZfZ7STuivwdVBeFe1HM4tepMxcq4I715uo+Bc24UiHXOlerfPVTTWj7RjASGaOE/ZujliLm0UoGtYouTJMluoQlW48kiGAfwimT642/dgS8JUczIJsUjndFdLIkzKQkDBNf0yVRxrebmz2ie8pWA/yJg01iGptKdBwXp6gk5+DhKHLP+5B7YQEtlVw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=gMiZVQ5uikdAZbdSJmQz0HHKZZOr++Izx2iEEvyXRPs=; b=TGJrilruKYNfbGKx30xntyvqilu86OVMZI61R6goAcjMmQfTz3hZXh/DrCbhDRaXA9qGMz51jRbPwONKXEr8k8EZ5gvuT9GIY+lLSJieWOqwXXbQRTmfhXWPS+qrWTJcYM0MM601Om9sOIrl8dGu4jcSsoWe5IVn6JYxC/9z8oM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) by VI0PR04MB11069.eurprd04.prod.outlook.com (2603:10a6:800:266::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7633.27; Thu, 6 Jun 2024 18:47:39 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06%2]) with mapi id 15.20.7633.021; Thu, 6 Jun 2024 18:47:39 +0000 From: Frank Li Date: Thu, 06 Jun 2024 14:47:01 -0400 Subject: [PATCH 7/7] arm64: dts: imx8qm-mek: add usb 3.0 and related type C nodes Message-Id: <20240606-imx8qm-dts-usb-v1-7-565721b64f25@nxp.com> References: <20240606-imx8qm-dts-usb-v1-0-565721b64f25@nxp.com> In-Reply-To: <20240606-imx8qm-dts-usb-v1-0-565721b64f25@nxp.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Dong Aisheng Cc: devicetree@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Frank Li X-Mailer: b4 0.13-dev-e586c X-Developer-Signature: v=1; a=ed25519-sha256; t=1717699632; l=3008; i=Frank.Li@nxp.com; s=20240130; h=from:subject:message-id; bh=V3aSz9OakazJIsc+Ir1XSAlA2aVt7bvWPkO3FQk4jxc=; b=a9hLZiTOJPt042ES1ZhCz5aBb52fNeB7ePrRoFwS5LPy6kBRGSk+Kc8hEWIaZ9GA3jcSgqILN HcmGOb4IuUhCtNPSWWqG6/ca840KNrVIiTJkcKBZi74oR7IHUJCXxny X-Developer-Key: i=Frank.Li@nxp.com; a=ed25519; pk=I0L1sDUfPxpAkRvPKy7MdauTuSENRq+DnA+G4qcS94Q= X-ClientProxiedBy: SJ0PR05CA0178.namprd05.prod.outlook.com (2603:10b6:a03:339::33) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|VI0PR04MB11069:EE_ X-MS-Office365-Filtering-Correlation-Id: 2665ee50-34f9-4258-22d3-08dc865923d0 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|52116005|376005|1800799015|7416005|366007|38350700005; X-Microsoft-Antispam-Message-Info: =?utf-8?q?VZKohaunYt5/Suly5Ri6egR9hXfBP6l?= =?utf-8?q?EFi3WIeDsNvycGWDSeW6TVCkcZ1zs3Du3ftsaikWsg32NGQXJWHKjEGpu4f+W1vWK?= =?utf-8?q?Svt4dMKTjpqj7dM4GDpIMek8InQ/T7ITVqjOSJfnm1Xw9X12dcnY0u4XbtHLMp/Ui?= =?utf-8?q?rUx7Q7DpKp7y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XbbneJhdeapt74NgrdlWKQ0PRsSTTDk/eWdwDucC7E4tOZD?= =?utf-8?q?sVAmwNPNV0VpMj6/iIo7WDnTudqqVolmrsNZKz0K8AfKLId7SGzabsSqzk4CqfC20?= =?utf-8?q?D/TpXccz7Gl+Y7/lMMR7Ji77zmmk/Y5S5JQk7HLz1aqu3+NFuwvJYIBiWI1PSe63D?= =?utf-8?q?SuvJtSqZ0PWHQUtkaJdCV2v/0CrVYvZDVukC69Jrcumometmpofm86VvAIrJHLF6T?= =?utf-8?q?jWeJTQgs/mRCrxf46+Aca0cm9EqTZi7m2xXMZq4WZDKGX5GDSo0sAjhM=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9642.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(52116005)(376005)(1800799015)(7416005)(366007)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?V10nojJhv3vWLnnQSbQxJTDUn+6g?= =?utf-8?q?Wcz2OaoE6VjCemEEPlZZVY130T5vISF1AzY0wlE71+tqeP3oKrBSk2ZSMOaVyVbYD?= =?utf-8?q?8KjftHkFg+mx1ozLfR1+EkKhv2XveVW4EJUYFZzXPO6dEjAF5OVi4hzaX8BFpMMZD?= =?utf-8?q?Xi0W8hgIxBmcWlgqco9DDjqI3eetRZ/Qpk2piZsMfzOxLAcdUKOgjxAJLLUIHxFCs?= =?utf-8?q?U1pnwK48qc/+At5QFBcESNV8MmIPaGGx5sUIMJhDGdvcdImgqOloMxb5ruxrlhmq9?= =?utf-8?q?+HqeYlfhznPcgjBsjsANY3Z9gNzJZSUpIsVpYu4Vtp+ZY7avdBiiq2M0b64tU1tBi?= =?utf-8?q?iCKCoiE+9/hIxfMvuVWHs8ewM1qd9Uc7PZvmGNujZhh5h3zBuZpRhP1ItC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?utf-8?q?Pgu6ESaLHTkTAehVygg1NXGTEKj35nysXbzd7k07fMLKAzg3mPxJXTnbkRhnqyTy3?= =?utf-8?q?Jfiv+5MJZ3qCwoF2aUeW7TlRLZQ1Nz3msVe2EGqgwTWtR8c6DDIA+MGs0qgZk0d3w?= =?utf-8?q?dTGkMxm9w+o3u1cB/6tf2iAXTjbZwowcvHAjcIeaWnkem4qV8xiWlf7xQYD9qsLyT?= =?utf-8?q?hVh17pQJbeV7H2HLtKCPJEK2YfNaNHB3gpOz0+oxCfpdD29gXJ99Vet5Af8gWnXUP?= =?utf-8?q?FIXqXxeKlr9G?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2665ee50-34f9-4258-22d3-08dc865923d0 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jun 2024 18:47:39.1722 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: IjrRZMX+Zd6axMTUrgtooZOliSe/oVWhdUol35VIXWOI5Oj0jITzFUn3VhaYMeNv7llRLFzsmgKv63hRiVwCbg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI0PR04MB11069 Enable usb3.0 and related usb type C nodes. Signed-off-by: Frank Li --- arch/arm64/boot/dts/freescale/imx8qm-mek.dts | 87 ++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8qm-mek.dts b/arch/arm64/boot/dts/freescale/imx8qm-mek.dts index dedcc1b1bf12f..f6e2f1573f6ab 100644 --- a/arch/arm64/boot/dts/freescale/imx8qm-mek.dts +++ b/arch/arm64/boot/dts/freescale/imx8qm-mek.dts @@ -7,6 +7,7 @@ /dts-v1/; #include "imx8qm.dtsi" +#include "dt-bindings/usb/pd.h" / { model = "Freescale i.MX8QM MEK"; @@ -129,6 +130,21 @@ lvds_backlight1: backlight-lvds1 { default-brightness-level = <80>; }; + gpio-sbu-mux { + compatible = "nxp,cbdtu02043", "gpio-sbu-mux"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_typec_mux>; + select-gpios = <&lsio_gpio4 6 GPIO_ACTIVE_LOW>; + enable-gpios = <&lsio_gpio4 19 GPIO_ACTIVE_HIGH>; + orientation-switch; + + port { + usb3_data_ss: endpoint { + remote-endpoint = <&typec_con_ss>; + }; + }; + }; + reg_usdhc2_vmmc: usdhc2-vmmc { compatible = "regulator-fixed"; regulator-name = "SD1_SPWR"; @@ -341,6 +357,44 @@ gyrometer@69 { compatible = "st,l3g4200d-gyro"; reg = <0x69>; }; + + ptn5110: tcpc@51 { + compatible = "nxp,ptn5110", "tcpci"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_typec>; + reg = <0x51>; + interrupt-parent = <&lsio_gpio4>; + interrupts = <26 IRQ_TYPE_LEVEL_LOW>; + status = "okay"; + + usb_con1: connector { + compatible = "usb-c-connector"; + label = "USB-C"; + power-role = "source"; + data-role = "dual"; + source-pdos = ; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + typec_dr_sw: endpoint { + remote-endpoint = <&usb3_drd_sw>; + }; + }; + + port@1 { + reg = <1>; + typec_con_ss: endpoint { + remote-endpoint = <&usb3_data_ss>; + }; + }; + }; + }; + }; }; &i2c1 { @@ -553,6 +607,26 @@ &usdhc2 { status = "okay"; }; +&usb3_phy { + status = "okay"; +}; + +&usbotg3 { + status = "okay"; +}; + +&usbotg3_cdns3 { + dr_mode = "otg"; + usb-role-switch; + status = "okay"; + + port { + usb3_drd_sw: endpoint { + remote-endpoint = <&typec_dr_sw>; + }; + }; +}; + &sai0 { #sound-dai-cells = <0>; assigned-clocks = <&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_PLL>, @@ -819,6 +893,19 @@ IMX8QM_SAI1_TXC_AUD_SAI1_TXC 0x06000040 >; }; + pinctrl_typec: typecgrp { + fsl,pins = < + IMX8QM_QSPI1A_DATA0_LSIO_GPIO4_IO26 0x00000021 + >; + }; + + pinctrl_typec_mux: typecmuxgrp { + fsl,pins = < + IMX8QM_QSPI1A_SS0_B_LSIO_GPIO4_IO19 0x60 + IMX8QM_USB_SS3_TC3_LSIO_GPIO4_IO06 0x60 + >; + }; + pinctrl_usdhc1: usdhc1grp { fsl,pins = < IMX8QM_EMMC0_CLK_CONN_EMMC0_CLK 0x06000041