From patchwork Mon Apr 10 17:10:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bhupesh Sharma X-Patchwork-Id: 672392 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 CB56FC76196 for ; Mon, 10 Apr 2023 17:11:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229711AbjDJRLD (ORCPT ); Mon, 10 Apr 2023 13:11:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39434 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230024AbjDJRLB (ORCPT ); Mon, 10 Apr 2023 13:11:01 -0400 Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 487DB2691 for ; Mon, 10 Apr 2023 10:10:29 -0700 (PDT) Received: by mail-pj1-x1036.google.com with SMTP id 60-20020a17090a09c200b0023fcc8ce113so7922257pjo.4 for ; Mon, 10 Apr 2023 10:10:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681146625; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=jPsBIL7uoiC5DZZtXnqdAvBon8Zv1+SeehoREZW26xk=; b=WKyH+NU7O1lfEavsxV/DZ9NCp2jLzdTEt+/XQkis4p3kHfa8SgP9vg+U1LVQmVr5Hu HeEUVtzjSMcBtHMqvbr1zyXxqsxY5dsVgQm7cjPxvvxUuKiUT1ZXWip42C1XyY3QL+ly QMJvWDCddS8b09celm9RPxai9ilrLXRGT1LAtKjIYQyINuuBakuKX1eVQv/ZBfFDU2e7 ffxeu3Weefh2yNky2GR1hiX+akwB4lO75pap6K3xWIcKF9roCM8e05QKlBdURTFPkOgh KMIzyHW4gvBOmurqlR4AmBSyA5qRrzVmth1eGTHhmq3+OP0b7TXxaP9yi6p8CX/pie+b 446Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681146625; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=jPsBIL7uoiC5DZZtXnqdAvBon8Zv1+SeehoREZW26xk=; b=EblTgwYJtY/y4k80AUSFsYnjyHhbfp7A0K3MxAGoNGMj0aYwyKudYw/q2kmNgFtTQP SnouYZYSs2BGafJ8BSjM0EuQ3TjVnHSbl4FK8RcBl3IcoBJNh8T48iwduRdUca7ST1zR dOmZDEUCdMeQoXwrT05JRMouySFh/QzFUePCiq0lWX6buQHR5owJoyAxGJ6vFzKJBjs9 ogM/+yEwsq4kvQT1IQHE+x3yvMFJjNv2LkGpweXK5bvMw1d1lxDpIAPRrlNBazI6GwC2 9OrGy7evn4rI9B0TBATllopnw8CtHaopPrjfy7dUfzWZbYLe2ZJI0juc1TW99W7IsnL2 8zNQ== X-Gm-Message-State: AAQBX9fpMqZ3KlSS72w8DeK8NbSvivx+eGAbLj+bIzU9e43hFbAhz+xf wlSAEpld3lP/KHEz7cDExtixzPdujpc0Zz1CISU= X-Google-Smtp-Source: AKy350b3DDWOlO2n8vNw3HQCLtQ8mZg6WZOCWMj5plEYAij8yx0YBSiPoOZxzYa44rMF9ePQb9SjFQ== X-Received: by 2002:a05:6a20:671d:b0:d8:a2ee:6b60 with SMTP id q29-20020a056a20671d00b000d8a2ee6b60mr7681531pzh.42.1681146624663; Mon, 10 Apr 2023 10:10:24 -0700 (PDT) Received: from localhost.localdomain ([2401:4900:1c60:6a11:8ba1:beba:def7:a4ae]) by smtp.gmail.com with ESMTPSA id q11-20020a63cc4b000000b0050bc4ca9024sm7187818pgi.65.2023.04.10.10.10.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Apr 2023 10:10:24 -0700 (PDT) From: Bhupesh Sharma To: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-phy@lists.infradead.org Cc: agross@kernel.org, linux-kernel@vger.kernel.org, andersson@kernel.org, bhupesh.sharma@linaro.org, bhupesh.linux@gmail.com, krzysztof.kozlowski@linaro.org, robh+dt@kernel.org, konrad.dybcio@linaro.org, kishon@kernel.org, vkoul@kernel.org, krzysztof.kozlowski+dt@linaro.org Subject: [PATCH v8 1/2] dt-bindings: phy: qcom,qmp-usb: Drop legacy bindings and move to newer one (SM6115 & QCM2290) Date: Mon, 10 Apr 2023 22:40:09 +0530 Message-Id: <20230410171010.2561393-2-bhupesh.sharma@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230410171010.2561393-1-bhupesh.sharma@linaro.org> References: <20230410171010.2561393-1-bhupesh.sharma@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org 'qcom,msm8996-qmp-usb3-phy.yaml' defines bindings for several PHYs which predate USB -> USB+DP migration. Since SM6115 and QCM2290 nodes for USB QMP phy are being added to dtsi files by followup patches, move these bindings instead to the newer style 'qcom,sc8280xp-qmp-usb3-uni-phy.yaml' file. Since no device trees use these bindings presently, so we have no ABI breakages with this patch. Signed-off-by: Bhupesh Sharma --- .../phy/qcom,msm8996-qmp-usb3-phy.yaml | 27 ------------ .../phy/qcom,sc8280xp-qmp-usb3-uni-phy.yaml | 44 ++++++++++++++++--- 2 files changed, 39 insertions(+), 32 deletions(-) diff --git a/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-usb3-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-usb3-phy.yaml index e81a38281f8c..4c96dab5b9e3 100644 --- a/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-usb3-phy.yaml +++ b/Documentation/devicetree/bindings/phy/qcom,msm8996-qmp-usb3-phy.yaml @@ -23,14 +23,12 @@ properties: - qcom,ipq8074-qmp-usb3-phy - qcom,msm8996-qmp-usb3-phy - qcom,msm8998-qmp-usb3-phy - - qcom,qcm2290-qmp-usb3-phy - qcom,sc7180-qmp-usb3-phy - qcom,sc8180x-qmp-usb3-phy - qcom,sdm845-qmp-usb3-phy - qcom,sdm845-qmp-usb3-uni-phy - qcom,sdx55-qmp-usb3-uni-phy - qcom,sdx65-qmp-usb3-uni-phy - - qcom,sm6115-qmp-usb3-phy - qcom,sm8150-qmp-usb3-phy - qcom,sm8150-qmp-usb3-uni-phy - qcom,sm8250-qmp-usb3-phy @@ -248,29 +246,6 @@ allOf: - const: phy - const: common - - if: - properties: - compatible: - contains: - enum: - - qcom,qcm2290-qmp-usb3-phy - - qcom,sm6115-qmp-usb3-phy - then: - properties: - clocks: - maxItems: 3 - clock-names: - items: - - const: cfg_ahb - - const: ref - - const: com_aux - resets: - maxItems: 2 - reset-names: - items: - - const: phy_phy - - const: phy - - if: properties: compatible: @@ -318,12 +293,10 @@ allOf: enum: - qcom,ipq6018-qmp-usb3-phy - qcom,ipq8074-qmp-usb3-phy - - qcom,qcm2290-qmp-usb3-phy - qcom,sc7180-qmp-usb3-phy - qcom,sc8180x-qmp-usb3-phy - qcom,sdx55-qmp-usb3-uni-phy - qcom,sdx65-qmp-usb3-uni-phy - - qcom,sm6115-qmp-usb3-phy - qcom,sm8150-qmp-usb3-uni-phy - qcom,sm8250-qmp-usb3-phy then: diff --git a/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-usb3-uni-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-usb3-uni-phy.yaml index 16fce1038285..05335e6bbb58 100644 --- a/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-usb3-uni-phy.yaml +++ b/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-usb3-uni-phy.yaml @@ -16,7 +16,9 @@ description: properties: compatible: enum: + - qcom,qcm2290-qmp-usb3-phy - qcom,sc8280xp-qmp-usb3-uni-phy + - qcom,sm6115-qmp-usb3-phy reg: maxItems: 1 @@ -25,11 +27,7 @@ properties: maxItems: 4 clock-names: - items: - - const: aux - - const: ref - - const: com_aux - - const: pipe + maxItems: 4 power-domains: maxItems: 1 @@ -71,6 +69,42 @@ required: additionalProperties: false +allOf: + - if: + properties: + compatible: + contains: + enum: + - qcom,qcm2290-qmp-usb3-phy + - qcom,sm6115-qmp-usb3-phy + then: + properties: + clocks: + maxItems: 4 + clock-names: + items: + - const: cfg_ahb + - const: ref + - const: com_aux + - const: pipe + + - if: + properties: + compatible: + contains: + enum: + - qcom,sc8280xp-qmp-usb3-uni-phy + then: + properties: + clocks: + maxItems: 4 + clock-names: + items: + - const: aux + - const: ref + - const: com_aux + - const: pipe + examples: - | #include From patchwork Mon Apr 10 17:10:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bhupesh Sharma X-Patchwork-Id: 672068 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 D245AC77B61 for ; Mon, 10 Apr 2023 17:11:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230078AbjDJRLG (ORCPT ); Mon, 10 Apr 2023 13:11:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39442 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230090AbjDJRLC (ORCPT ); Mon, 10 Apr 2023 13:11:02 -0400 Received: from mail-pj1-x1034.google.com (mail-pj1-x1034.google.com [IPv6:2607:f8b0:4864:20::1034]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C30F0269A for ; Mon, 10 Apr 2023 10:10:30 -0700 (PDT) Received: by mail-pj1-x1034.google.com with SMTP id y11-20020a17090a600b00b0024693e96b58so3932345pji.1 for ; Mon, 10 Apr 2023 10:10:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681146629; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=pNoQs5qOgvjqSthHiZStB/bBkE2Kj3/X8lWJDBkoV6Y=; b=jfTLQRUATkVI4UyXndhSZTFq4zka6G64hOkBEPE+GI1vSBNS5Us/TQ2tHz5QvQu4mx Ty/CfI2LgqkSLgX6K1DJO4/KZLljzu7fa6xy7GOC4+se1ipi0QqDN+0FS15p30NmmZz9 KpIgt6CsdtUli9qTwpp68fj2nZCf0yPurZZ6JceW2q5MzYbicYHXeIUxMHLGkKnxF1vN JmqOp9P4FKwM8WZA09dqNPaaUSf5sEXXCEk30D7nju+0grg7rEL9e/vOa0xFun9dYNYN ZJpJys8sNs3h3IoTwxp1offubQ/ly9LHrGk8Jpy5qUUYWjfyZl6fLptT6smU3XPcUi2E sUHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681146629; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pNoQs5qOgvjqSthHiZStB/bBkE2Kj3/X8lWJDBkoV6Y=; b=wZP281tQxp5TKor4nA10l2kF+uLiyJBnHCw95OoVxwA6HGperI/cIowbFIBWZ5i8rj wwxyUgfe6ry78LKzz4az2gH+m3SqpTRcXt7qQe2ctsuWJA8vApiLHABrmP7/huqvM+XX 8Tdb0BlGTxViV0MdU4lBi8RESuNQP4g9RKzVdaU4wrjs3mRaVv7uJZWKpEv0cMPCTeUS lX8TvWeYqIigouqfRFWW5N3u12CmwKb8HzJuEjlibsBb5lQJCgnKEUlGU6J8UsUU877q hF+3SUaWutC0hcJe0rhjxYtzbm9V6gdLdQf04IhNuqSOdG1jZxVlfzZjcYaH92d7un6S JO5g== X-Gm-Message-State: AAQBX9djWRrW0eoEGs8NRCy75naQPUKTOeKylq4RxbognptkfOwAxGr0 aW3eZ1zmvTZjlpq+88Ycg/nFjiI4aQbVH+gS5no= X-Google-Smtp-Source: AKy350Z+Yv1n0ctaOMR7TjVcAmZKU+AeThDZl/VfKw0+mm/6qA758RJtMnSRdxl6YXfQyLf7oyWN6Q== X-Received: by 2002:a05:6a20:1452:b0:bf:58d1:ce94 with SMTP id a18-20020a056a20145200b000bf58d1ce94mr17024279pzi.19.1681146629454; Mon, 10 Apr 2023 10:10:29 -0700 (PDT) Received: from localhost.localdomain ([2401:4900:1c60:6a11:8ba1:beba:def7:a4ae]) by smtp.gmail.com with ESMTPSA id q11-20020a63cc4b000000b0050bc4ca9024sm7187818pgi.65.2023.04.10.10.10.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Apr 2023 10:10:29 -0700 (PDT) From: Bhupesh Sharma To: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-phy@lists.infradead.org Cc: agross@kernel.org, linux-kernel@vger.kernel.org, andersson@kernel.org, bhupesh.sharma@linaro.org, bhupesh.linux@gmail.com, krzysztof.kozlowski@linaro.org, robh+dt@kernel.org, konrad.dybcio@linaro.org, kishon@kernel.org, vkoul@kernel.org, krzysztof.kozlowski+dt@linaro.org Subject: [PATCH v8 2/2] arm64: dts: qcom: sm6115: Add USB SS qmp phy node Date: Mon, 10 Apr 2023 22:40:10 +0530 Message-Id: <20230410171010.2561393-3-bhupesh.sharma@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230410171010.2561393-1-bhupesh.sharma@linaro.org> References: <20230410171010.2561393-1-bhupesh.sharma@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add USB superspeed qmp phy node to dtsi. Make sure that the various board dts files (which include sm4250.dtsi file) continue to work as intended. Signed-off-by: Bhupesh Sharma --- .../boot/dts/qcom/sm4250-oneplus-billie2.dts | 3 ++ arch/arm64/boot/dts/qcom/sm6115.dtsi | 29 +++++++++++++++++-- .../boot/dts/qcom/sm6115p-lenovo-j606f.dts | 3 ++ 3 files changed, 33 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm4250-oneplus-billie2.dts b/arch/arm64/boot/dts/qcom/sm4250-oneplus-billie2.dts index a1f0622db5a0..75951fd439df 100644 --- a/arch/arm64/boot/dts/qcom/sm4250-oneplus-billie2.dts +++ b/arch/arm64/boot/dts/qcom/sm4250-oneplus-billie2.dts @@ -242,6 +242,9 @@ &usb { &usb_dwc3 { maximum-speed = "high-speed"; dr_mode = "peripheral"; + + phys = <&usb_hsphy>; + phy-names = "usb2-phy"; }; &usb_hsphy { diff --git a/arch/arm64/boot/dts/qcom/sm6115.dtsi b/arch/arm64/boot/dts/qcom/sm6115.dtsi index 2505c815c65a..b2ea8f13e827 100644 --- a/arch/arm64/boot/dts/qcom/sm6115.dtsi +++ b/arch/arm64/boot/dts/qcom/sm6115.dtsi @@ -651,6 +651,31 @@ usb_hsphy: phy@1613000 { status = "disabled"; }; + usb_qmpphy: phy@1615000 { + compatible = "qcom,sm6115-qmp-usb3-phy"; + reg = <0x0 0x01615000 0x0 0x200>; + + clocks = <&gcc GCC_AHB2PHY_USB_CLK>, + <&gcc GCC_USB3_PRIM_CLKREF_CLK>, + <&gcc GCC_USB3_PRIM_PHY_COM_AUX_CLK>, + <&gcc GCC_USB3_PRIM_PHY_PIPE_CLK>; + clock-names = "cfg_ahb", + "ref", + "com_aux", + "pipe"; + + resets = <&gcc GCC_USB3_PHY_PRIM_SP0_BCR>, + <&gcc GCC_USB3PHY_PHY_PRIM_SP0_BCR>; + reset-names = "phy", "phy_phy"; + + #clock-cells = <0>; + clock-output-names = "usb3_phy_pipe_clk_src"; + + #phy-cells = <0>; + + status = "disabled"; + }; + qfprom@1b40000 { compatible = "qcom,sm6115-qfprom", "qcom,qfprom"; reg = <0x0 0x01b40000 0x0 0x7000>; @@ -1101,8 +1126,8 @@ usb_dwc3: usb@4e00000 { compatible = "snps,dwc3"; reg = <0x0 0x04e00000 0x0 0xcd00>; interrupts = ; - phys = <&usb_hsphy>; - phy-names = "usb2-phy"; + phys = <&usb_hsphy>, <&usb_ssphy>; + phy-names = "usb2-phy", "usb3-phy"; iommus = <&apps_smmu 0x120 0x0>; snps,dis_u2_susphy_quirk; snps,dis_enblslpm_quirk; diff --git a/arch/arm64/boot/dts/qcom/sm6115p-lenovo-j606f.dts b/arch/arm64/boot/dts/qcom/sm6115p-lenovo-j606f.dts index 10c9d338446c..d60cc024749b 100644 --- a/arch/arm64/boot/dts/qcom/sm6115p-lenovo-j606f.dts +++ b/arch/arm64/boot/dts/qcom/sm6115p-lenovo-j606f.dts @@ -280,6 +280,9 @@ &usb { &usb_dwc3 { maximum-speed = "high-speed"; dr_mode = "peripheral"; + + phys = <&usb_hsphy>; + phy-names = "usb2-phy"; }; &usb_hsphy {