Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp6155591rwd; Mon, 19 Jun 2023 03:14:59 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5mhnxcuk7M5Sup60WTr0f+KQnGZlE0G3ytakSOz+QbS6OagJppuXPCRaEKfd7LIHJcPxKY X-Received: by 2002:a05:6a00:150f:b0:665:c37f:759e with SMTP id q15-20020a056a00150f00b00665c37f759emr576429pfu.6.1687169699599; Mon, 19 Jun 2023 03:14:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687169699; cv=none; d=google.com; s=arc-20160816; b=mTBUZ1/2D2iDcq19H9PYjor5sTe6vRY26JzLpmGTmS1jAtGX14ksijkh24xe05IIdB amueHRGmcwVYRZ33CV2K4lo1BbR0kd+Gc1iRCRT20AkjBx8dciSwKAeuxcm5pM3dGswe vXgU8AU9mJowMSX0VI+q95gTXwjhsukBcrlcee0lFGulU39JSprcP1dKjro6yLKONIJs Eo6Tn7VLGFfy+DR4qVRmLGuDAqM8PQk5/kIrcClsBGG3rxU6fN9Yxa0fafEYVYkzccNr RFANZfA4QauRMKznMyDenbWujxysnRNCuFL0U3vGyw2t2mMYfBIn76sp711+f4wMHbeW dZIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=3/qEdMe1vO0ki74QhucDrIEu24HnPwPhBB6LzpcaIbQ=; b=VYnP1+x0L/jdQOGpsogc2v48W/NDl+FYPjEcZyHdNRj3ZGG/ucsWChY7PxZ3nM0nCw g1mGisK7tgOntzpMdgxlqX5dow95RC+kl6ynun1B85t8GJQU13NEKqCOGwmB0Pm0RYLn KoOomz+4mBZH7Xwja9Lr0Cp2pNePaf9FeJ2OQLYYLEez2Z/TFucx0M5XLdHGbgSwjY8G kUB0WmlqAj15fZNVJU2NRImnf4dsMzb84JlKALpXyFdh8c/b22VY3DFub2eLYj4Un2P6 5mSt4r1M728rJcbETnu+bAZ8J2VhkxOkJUYsseEPQj43iBb7ZNm4CCB8IROMJ2ah0gGR H5vA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t20-20020aa79474000000b006688598a346si661507pfq.138.2023.06.19.03.14.45; Mon, 19 Jun 2023 03:14:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231685AbjFSJsi (ORCPT + 99 others); Mon, 19 Jun 2023 05:48:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229489AbjFSJsQ (ORCPT ); Mon, 19 Jun 2023 05:48:16 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 354F11AB; Mon, 19 Jun 2023 02:48:09 -0700 (PDT) Received: from EXMBX165.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX165", Issuer "EXMBX165" (not verified)) by ex01.ufhost.com (Postfix) with ESMTP id 4454124DD82; Mon, 19 Jun 2023 17:48:02 +0800 (CST) Received: from EXMBX171.cuchost.com (172.16.6.91) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 19 Jun 2023 17:48:02 +0800 Received: from ubuntu.localdomain (113.72.145.217) by EXMBX171.cuchost.com (172.16.6.91) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 19 Jun 2023 17:48:01 +0800 From: Minda Chen To: Emil Renner Berthing , Conor Dooley , Vinod Koul , Kishon Vijay Abraham I , Rob Herring , Krzysztof Kozlowski , Roger Quadros CC: , , , , "Paul Walmsley" , Palmer Dabbelt , Albert Ou , Minda Chen , Mason Huo Subject: [PATCH v7 0/7] Add JH7110 USB PHY driver support Date: Mon, 19 Jun 2023 17:47:54 +0800 Message-ID: <20230619094759.21013-1-minda.chen@starfivetech.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [113.72.145.217] X-ClientProxiedBy: EXCAS066.cuchost.com (172.16.6.26) To EXMBX171.cuchost.com (172.16.6.91) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patchset adds USB and PCIe PHY for the StarFive JH7110 SoC. The patch has been tested on the VisionFive 2 board. This patchset is base on v6.4-rc6 patch 1 is usb phy dt-binding document. patch 2 is Pcie PHY dt-binding document. patch 3 is USB 2.0 PHY driver. patch 4 is PCIe PHY driver. patch 5 is PCIe PHY dts Previous version are merged with USB controller patch. For USB controller patch is accepted. Now remove the USB controller patch. And remove the dependency. previous change can be seen list below. (start from old patch set v3) v3: https://patchwork.kernel.org/project/linux-phy/cover/20230315104411.73614-1-minda.chen@starfivetech.com/ v4: https://patchwork.kernel.org/project/linux-phy/cover/20230406015216.27034-1-minda.chen@starfivetech.com/ v5: https://patchwork.kernel.org/project/linux-phy/cover/20230420110052.3182-1-minda.chen@starfivetech.com/ v6: https://patchwork.kernel.org/project/linux-phy/cover/20230518112750.57924-1-minda.chen@starfivetech.com/ changes: v7: (patch3 and patch 4) Add /driver/phy/starfive directory, Makefile and Kconfig. Remove the dependency. (patch 5) add PCIe PHY dts configuration. (USB 2.0 PHY clock reply on other patch, Dont add this first). v6: 1. (patch 3) remove the platform remove function. 2. (patch 4) - add switch to pcie mode function. - remove the redundant init/exit function. v5: 1. (patch 1) set correct model name and commit title. 2. (patch 2) change to '-item' in syscon property. change commit title. v4: 1. (patch 1) split PCIe PHY dt-binding doc to patch 2. 2. (patch 2) PCIe PHY add stg and sys con configuration to dt-binding doc. 3. (patch 3) - split PCIe PHY driver to patch 4. - replace dr_mode to phy mode in jh7110_usb2_phy. 4. (patch 4) - Makefile and Kconfig sorted by alphabet sequence. - Add PCIe PHY stg and syscon PHY connection configuration for USB 3.0. v3: 1. Add patch 1 - 4. Add USB PHY driver and dt-binding doc. USB PHY codes are moved to patch 3 and patch 4. Minda Chen (5): dt-bindings: phy: Add StarFive JH7110 USB PHY dt-bindings: phy: Add StarFive JH7110 PCIe PHY phy: starfive: Add JH7110 USB 2.0 PHY driver phy: starfive: Add JH7110 PCIE 2.0 PHY driver riscv: dts: starfive: Add PCIe PHY dts configuration for JH7110 .../phy/starfive,jh7110-pcie-phy.yaml | 58 +++++ .../bindings/phy/starfive,jh7110-usb-phy.yaml | 50 +++++ MAINTAINERS | 8 + arch/riscv/boot/dts/starfive/jh7110.dtsi | 12 ++ drivers/phy/Kconfig | 1 + drivers/phy/Makefile | 1 + drivers/phy/starfive/Kconfig | 25 +++ drivers/phy/starfive/Makefile | 3 + drivers/phy/starfive/phy-jh7110-pcie.c | 204 ++++++++++++++++++ drivers/phy/starfive/phy-jh7110-usb.c | 150 +++++++++++++ 10 files changed, 512 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/starfive,jh7110-pcie-phy.yaml create mode 100644 Documentation/devicetree/bindings/phy/starfive,jh7110-usb-phy.yaml create mode 100644 drivers/phy/starfive/Kconfig create mode 100644 drivers/phy/starfive/Makefile create mode 100644 drivers/phy/starfive/phy-jh7110-pcie.c create mode 100644 drivers/phy/starfive/phy-jh7110-usb.c base-commit: 858fd168a95c5b9669aac8db6c14a9aeab446375 -- 2.17.1