From patchwork Tue Mar 21 15:19:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 665659 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36A4FC7619A for ; Tue, 21 Mar 2023 15:20:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231454AbjCUPUR (ORCPT ); Tue, 21 Mar 2023 11:20:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43250 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231604AbjCUPUQ (ORCPT ); Tue, 21 Mar 2023 11:20:16 -0400 Received: from EUR03-DBA-obe.outbound.protection.outlook.com (mail-dbaeur03on2082.outbound.protection.outlook.com [40.107.104.82]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 20F1C8694; Tue, 21 Mar 2023 08:20:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Z8wDSpWAelvCo9u4gdqvl7F9qVan2RhJmdapHMBI4AgF+4VUSlW5VPD0veq/wfctveDsgHRiu/XO6EE6y39E9n8tHpRMSje8T4TMyKv+4oZ4Dk1ktTbx2JmZhIgHjUdQwjqOU9FdziLx00kqkVVm8skPls4gekOFUBMgtRNmaWQPIekhInvmFPyDCstKxj/iJ5RC996SwTr7bNHl3sfrQn0vEhs2DDq56Haj9dniId3NHj2DfOjZS7w6kkD75PxS79bsbJNaU0ToQcjrj1iMBCur9bR469qXY5iW4G2N8q4aFePkk/TNxU4uK4Q6LFL+FJD2pf5uZL6tmjwwKE77hQ== 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=dbEV+XTNDWDhovZ1pgUh5UVARFRluoySO3UdNU69N5I=; b=TAX6EIerZ5joeDktYZz0zeeFXxI1GjwnXF3FUftc7wBqF0XIBKJTrzU7nmSLzPg456oXEwGWTaC3IhPF/oN5Lss2g0RTb57IPOxIB4n3gWSXtV2DyHai3ei8xf2nLzT41A6Qp1bNN2VBbZJYpIQEAG355iV2uVUGQgaOSds/tCLCsyPDqReFgEZvPRKtqJR4cZArLRpN0/flsYEOOe6ZkCydobQxnIPf8A/G825RAhgIMck7Ko6+HUTHlHM3/BOl6U/3wSss4XhUU2/cbCsljEbmIfJECX7L7Ji5GLrOjYSxZ9DB0iC/gNZ9u+/W3d9ic050Y+HKMTVDJl0ENvICUw== 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=dbEV+XTNDWDhovZ1pgUh5UVARFRluoySO3UdNU69N5I=; b=NI3QGz21uehJtQu9KmtCzTRCIcuHiqqBqyzc3yy6729QAfzKwwDyVX8gc4xp9TBIS1tWPoFdxHgz/uA+R9aT25psCqiTw+R+BL2fTi8O+mSOQVKEkULZ8fX9m+ezTolQXVJq0U+l0muG+M7gZO87QxxZH4pwm8la9npA/blee2E= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM6PR04MB4838.eurprd04.prod.outlook.com (2603:10a6:20b:4::16) by AS8PR04MB8819.eurprd04.prod.outlook.com (2603:10a6:20b:42e::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.37; Tue, 21 Mar 2023 15:20:13 +0000 Received: from AM6PR04MB4838.eurprd04.prod.outlook.com ([fe80::fb2a:a683:b78e:b9b5]) by AM6PR04MB4838.eurprd04.prod.outlook.com ([fe80::fb2a:a683:b78e:b9b5%4]) with mapi id 15.20.6178.037; Tue, 21 Mar 2023 15:20:13 +0000 From: Frank Li To: krzysztof.kozlowski@linaro.org Cc: devicetree@vger.kernel.org, festevam@gmail.com, frank.li@nxp.com, imx@lists.linux.dev, kernel@pengutronix.de, krzysztof.kozlowski+dt@linaro.org, linux-arm-kernel@lists.infradead.org, linux-imx@nxp.com, linux-kernel@vger.kernel.org, robh+dt@kernel.org, s.hauer@pengutronix.de, shawnguo@kernel.org Subject: [PATCH v3 1/3] dt-bindings: usb: cdns-imx8qm: add imx8qm cdns3 glue bindings Date: Tue, 21 Mar 2023 11:19:49 -0400 Message-Id: <20230321151951.2784286-2-Frank.Li@nxp.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230321151951.2784286-1-Frank.Li@nxp.com> References: <20230321151951.2784286-1-Frank.Li@nxp.com> X-ClientProxiedBy: BY5PR13CA0014.namprd13.prod.outlook.com (2603:10b6:a03:180::27) To AM6PR04MB4838.eurprd04.prod.outlook.com (2603:10a6:20b:4::16) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM6PR04MB4838:EE_|AS8PR04MB8819:EE_ X-MS-Office365-Filtering-Correlation-Id: c58fedf3-ddd6-4a3c-0baf-08db2a1fc445 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: pkykXsbspKUn6M+c2YQM5aVz9chLJdBLXWaRUEd1E42zXAZHvDmov5Cl9Arm7OVNFWyT1Gyy/0cHM8TlxcVgVRytQNBULTu9A5V+J5UjCLN3XQn6IRBXO4R57Ry28wYIuwDKuXrQBrZBpQv9MO6yzgax/PDWrVfpcUV/iZalqlGxwLYYg90+g2AGIrLhMnsdm1W8slUB0W50CtCVUFbVBLdBVcgoCQIHG+hRRXl0eTLSy4fM+/B8T2dNf1zkTmumQkCcinQMvbJChB2NdhFYTuefmlSdyxm9kpdykUCi4G0Jy89GaCVZ7hc94gW9tt0hFeiJkrN/xM2Zx+/GYM/0a2MfDvFS77Gq3mHT9IjF5eqEs9455HUoSWeNxhWFuuipZK+af0oLo4/YhvB1dkyxEPWYVg0iirUuFyYBtR+XCc9+ai5v9si8u82q6U1A3LzQA6PAAvLiCp9DUuloXWVOKM/P48WIEQ84JKAuzRoPAG5FoRhF9zpidQYHCyOFvRu9BchjRnL/k+vZ/QqjYQmOlanGO3pIxWG5nnmLWWQw8eEZTPpZVCrHqfIhKzp8UhiFL7PHBEvkGM2DLMyCJ/zXZKShYF17e8gvorbvLywdwjQm7V5e/y8wEL52eW+bySqK2TFFEJ061T1UlHAIITMXR0JVDZmlvpVyHmkaVydzmPErgyE67eli15MGwfFdPA/QEI/IiU8DRRezgUFJhhmUhZBWKrH+YTYs5ExCjbInH6sQumsJo/frZwDPO5gcvxx0 X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM6PR04MB4838.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230025)(4636009)(376002)(396003)(346002)(136003)(366004)(39860400002)(451199018)(8936002)(41300700001)(5660300002)(7416002)(4326008)(86362001)(36756003)(38100700002)(2906002)(38350700002)(6916009)(966005)(6486002)(83380400001)(478600001)(52116002)(6506007)(2616005)(6666004)(186003)(26005)(1076003)(316002)(8676002)(6512007)(66556008)(66946007)(66476007)(32563001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: TebVjJN9sQfD87HmDR4F6l5LU4sr0abH2Fcmp4Ns7uJ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ZspBUWntc/QCwIU3ZvbTW8QICULRLPwztI3GlUimJxW70foCk7q3yOEkL7yp8epIfDIeyxUIKSvkS5LS6M7yKaaS6MuxkF/Fo9vLr99q0+rlTuk+rt8bMKfmNf/aTt3O+MeTg20Xtq2kRRnLs5Z3sP2JRMNDG96MsgthzC6yx3scw4acWnr/ToHwIVdn/mf9UA6OPy/jknW6xX5yk35P+nIEBsSgELhhKpRcFmnGxaaDJZm9B+BcwOnuDKmhXZfZblKnW3HxXxADvcReSMSNZBbFEj7Xy/txub8WtVJOXLecBl/EgyVsXPUmvUK0rqB7441cqOslBAROgBFLBqH4jF9omqFKefpQiOfxt8o3xehZI1yCbuaB9Bsg6yy4iaVjrlB+HVsGiONmcO2pQ6EdMygaf9lxqhyJkUix9MNG93JDF+vB6SNpJ5G2FUGhcNMUrRwaAvVEObnxT/R8ZCj1/pJxUvYyKdIqVsz X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: c58fedf3-ddd6-4a3c-0baf-08db2a1fc445 X-MS-Exchange-CrossTenant-AuthSource: AM6PR04MB4838.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Mar 2023 15:20:12.9987 (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: Rs6BHFw33oYSKcwMouV1It8ThEkDZK+uUSrz/LpwWHFvnZj9iujgGb2YQ4lMJr0fNog+G8u1mi3T4B14HKwAMw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR04MB8819 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org NXP imx8qm integrates 1 cdns3 IP. This is glue layer device bindings. Signed-off-by: Frank Li --- Change from v2 to v3 - Drop two fixed frequency clocks, it is system reset value, no need set now. If need, futher work/discuss on driver or dts change. It will not block this basic enablement work. - Drop lable - Drop some descriptions - Reg as second property. Change from v1 to v2. - new add binding doc .../bindings/usb/fsl,imx8qm-cdns3.yaml | 114 ++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 Documentation/devicetree/bindings/usb/fsl,imx8qm-cdns3.yaml diff --git a/Documentation/devicetree/bindings/usb/fsl,imx8qm-cdns3.yaml b/Documentation/devicetree/bindings/usb/fsl,imx8qm-cdns3.yaml new file mode 100644 index 000000000000..d876e3dab608 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/fsl,imx8qm-cdns3.yaml @@ -0,0 +1,112 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +# Copyright (c) 2020 NXP +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/fsl,imx8qm-cdns3.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP iMX8QM Soc USB Controller + +maintainers: + - Frank Li + +properties: + compatible: + const: fsl,imx8qm-usb3 + + reg: + items: + - description: Register set for iMX USB3 Platform Control + + "#address-cells": + enum: [ 1, 2 ] + + "#size-cells": + enum: [ 1, 2 ] + + ranges: true + + clocks: + items: + - description: Standby clock. Used during ultra low power states. + - description: USB bus clock for usb3 controller. + - description: AXI clock for AXI interface. + - description: ipg clock for register access. + - description: Core clock for usb3 controller. + + clock-names: + items: + - const: usb3_lpm_clk + - const: usb3_bus_clk + - const: usb3_aclk + - const: usb3_ipg_clk + - const: usb3_core_pclk + + assigned-clocks: + items: + - description: Phandle and clock specifoer of IMX_SC_PM_CLK_MST_BUS. + + assigned-clock-rates: + items: + - description: Should be in Range 100 - 600 Mhz. + + power-domains: + maxItems: 1 + +# Required child node: + +patternProperties: + "^usb@[0-9a-f]+$": + $ref: cdns,usb3.yaml# + +required: + - compatible + - reg + - "#address-cells" + - "#size-cells" + - ranges + - clocks + - clock-names + - power-domains + +additionalProperties: false + +examples: + - | + #include + #include + #include + + usb@5b110000 { + compatible = "fsl,imx8qm-usb3"; + reg = <0x5b110000 0x10000>; + ranges; + clocks = <&usb3_lpcg IMX_LPCG_CLK_1>, + <&usb3_lpcg IMX_LPCG_CLK_0>, + <&usb3_lpcg IMX_LPCG_CLK_7>, + <&usb3_lpcg IMX_LPCG_CLK_4>, + <&usb3_lpcg IMX_LPCG_CLK_5>; + clock-names = "usb3_lpm_clk", "usb3_bus_clk", "usb3_aclk", + "usb3_ipg_clk", "usb3_core_pclk"; + assigned-clocks = <&clk IMX_SC_R_USB_2 IMX_SC_PM_CLK_MST_BUS>; + assigned-clock-rates = <250000000>; + power-domains = <&pd IMX_SC_R_USB_2>; + #address-cells = <1>; + #size-cells = <1>; + + usb@5b120000 { + compatible = "cdns,usb3"; + reg = <0x5b120000 0x10000>, /* memory area for OTG/DRD registers */ + <0x5b130000 0x10000>, /* memory area for HOST registers */ + <0x5b140000 0x10000>; /* memory area for DEVICE registers */ + reg-names = "otg", "xhci", "dev"; + interrupt-parent = <&gic>; + interrupts = , + , + , + ; + interrupt-names = "host", "peripheral", "otg", "wakeup"; + phys = <&usb3_phy>; + phy-names = "cdns3,usb3-phy"; + }; + };