From patchwork Mon May 1 12:11:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678339 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 26F28C7EE30 for ; Mon, 1 May 2023 12:11:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232503AbjEAMLY (ORCPT ); Mon, 1 May 2023 08:11:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47570 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232484AbjEAMLU (ORCPT ); Mon, 1 May 2023 08:11:20 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 10E28138 for ; Mon, 1 May 2023 05:11:19 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-3f315735514so128911345e9.1 for ; Mon, 01 May 2023 05:11:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943077; x=1685535077; 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=9lSyNZ2HtWZEUWBo+n5QAmOJQC6AAMQbbNN6fuawseI=; b=Tlwmq14PmtSt/fi73yxsXirMZfGjtTpb0rwCBmtx48o75eV4xa62T3pLi6MoVj5pdx jSg+vcxHzrLUITmH1Hhc5L7bucqfXj+JeL2LFVwpnoYYu79MtGOe1detvixONSN5DZuB xeIiYwCvroeWOl90wJsnmapKeXvvncbBHF8RMI+XxMnhMhUAAsE53lky6IVOeSB9eU+x 2o5+xm9gP9c5BR9EIcMCMbjdwRNZHIk1GSWyKj/B53EH7dVTXcHYI4KZkdqMzz7Ej9sI AtHjY9n6N3uwalbmXpaJ/QiIUsww4++aEGKA7RCzauX0hjeFX6typW5xjlj53kpXOVVH xXig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943077; x=1685535077; 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=9lSyNZ2HtWZEUWBo+n5QAmOJQC6AAMQbbNN6fuawseI=; b=GP28LDdZtzuDMgXFUlIlp4iUPXnaeglFXgBJoQBrFGzYhU0xWrJJZmLhuhDIE0X00w QwH9lf8GcGvB759NTt1RecOiPmUcapoRwSa5sidM89pgp8kUaPfD08hydx2+xtHyk0k7 E2MVEmgB6CJ4N+78HUtrUOH2Ff4YZOJxbHuKPWjMRY8IWPBKRlo9V83mG6BSNn2pp8ZV Lf5WJuvO5+KFPnXhYEiIOWLSQRd8NoWIvc+QmpvkWWdV9Ip79TinF09QeU8lYxbDAbNe xYHXykGuYgzpmfzlK6Oopv0SMNZB8wJi6XJ4Z0Oiy5CPIC80TTC3nj6yCsMyfc8cvwO+ fUhQ== X-Gm-Message-State: AC+VfDwMlWuXzapJBT59Itw341bkMez9efwrPyA2Zs9GnOrZwVM/XplL C7dQt1n6DX4O1HvkgxE/+N1E6g== X-Google-Smtp-Source: ACHHUZ4Yy5Qoa+ZqUjN20+x8UJuF5y3PoKO5MisE7R4CvA9faJbt6neUhrQTxYXFGHV1VGYaOgS3zQ== X-Received: by 2002:a1c:f717:0:b0:3f1:71d3:8ddf with SMTP id v23-20020a1cf717000000b003f171d38ddfmr8603590wmh.14.1682943077519; Mon, 01 May 2023 05:11:17 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:17 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com, Krzysztof Kozlowski Subject: [PATCH v6 03/13] dt-bindings: phy: qcom,sc7180-qmp-usb3-dp-phy: Add orientation-switch as optional Date: Mon, 1 May 2023 13:11:01 +0100 Message-Id: <20230501121111.1058190-4-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org orientation-switch it the standard declaration to inform the Type-C mux layer that a remote-endpoint is capable of processing orientation change messages. Add as an optional since not all versions of the dp-phy currently support the orientation-switch. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Bryan O'Donoghue --- .../bindings/phy/qcom,sc7180-qmp-usb3-dp-phy.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Documentation/devicetree/bindings/phy/qcom,sc7180-qmp-usb3-dp-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,sc7180-qmp-usb3-dp-phy.yaml index 0ef2c9b9d4669..d307343388888 100644 --- a/Documentation/devicetree/bindings/phy/qcom,sc7180-qmp-usb3-dp-phy.yaml +++ b/Documentation/devicetree/bindings/phy/qcom,sc7180-qmp-usb3-dp-phy.yaml @@ -61,6 +61,10 @@ properties: power-domains: maxItems: 1 + orientation-switch: + description: Flag the port as possible handler of orientation switching + type: boolean + resets: items: - description: reset of phy block. @@ -251,6 +255,8 @@ examples: vdda-phy-supply = <&vdda_usb2_ss_1p2>; vdda-pll-supply = <&vdda_usb2_ss_core>; + orientation-switch; + usb3-phy@200 { reg = <0x200 0x128>, <0x400 0x200>, From patchwork Mon May 1 12:11:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678338 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 D3663C7EE2C for ; Mon, 1 May 2023 12:11:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232505AbjEAML0 (ORCPT ); Mon, 1 May 2023 08:11:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232502AbjEAMLX (ORCPT ); Mon, 1 May 2023 08:11:23 -0400 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2B1E199 for ; Mon, 1 May 2023 05:11:21 -0700 (PDT) Received: by mail-wr1-x434.google.com with SMTP id ffacd0b85a97d-2fa36231b1cso1380939f8f.2 for ; Mon, 01 May 2023 05:11:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943080; x=1685535080; 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=sEAWIVAO8TCad9eUCpAgUfIQC7M2awX7qB9SEkGVDac=; b=IwLb+E56usqyA/JioJ/a9nbZTIAcwT0HQTYUQVkxR2LjgmWA0Qf5CgqQ0OrLg6hdDr 9330RWxIQlvgrRjd3+ldlwJh3sXtXkrv0QPN8HXPgiHg2g1/2N19Yxa1lBN7IUosPjRH 7b4DfnWZcOf2Z6JQege3SDwEmsBICvXwe8UY8BkuqS+MAQSGwq+ZnG8AG3fDvGwA8yla 7eKa8moGcfIBZ+AttMJvOn9LtJ09D9gxMEZHuAjpgMCK1/H6bARlNTtqBKBm9kU7MVGZ YAp4ctx8WUq+JPFtG3XXQpaffJFdScGceRgzgwl4Im5PWNxBR2L/HJL2XBq2J3kQlhRh cWDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943080; x=1685535080; 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=sEAWIVAO8TCad9eUCpAgUfIQC7M2awX7qB9SEkGVDac=; b=IqZpxHFskRB6MfAm8C1Bki7Jqn29EDfosxu5ZvBmnEljPepwwNjA2dqxhR0puI+yvi CzZawDGbuEuKfbCr7Fmmzw1RusXv/xiM1L8W7jWZuIS27gej1gYeP5pZ7AUhrdoikLKn p99e4IFAqJOIYGOrq61cp3M1BzyuoHTlsT2z3D5Jn6MSr8eqWDS5ZNvaYO+jJQRJzjKg WuBlrP3nDcA/ZUfdFRjfiGnxsbTgzEBl/6DQzOFRc4DvbL9ENRLJNkzxy9wD1lcEwJVF KdqxQqXf76Z2xEKSWhk7+EG16WxIfXZrVjK3pzjNPcNRfaBmSLaF8wkGXqOFVz4os5AQ 5y4A== X-Gm-Message-State: AC+VfDxl1ux5HOMR8Nc6e/q1XZyadgAhxWCnLe1xEClJM+ANx8nKi+GI vD/4NktmkfUyL5R/nQdylyAW7Q== X-Google-Smtp-Source: ACHHUZ4Gf5kVsEf393H0tjUWLhGueZN0Wk3ukc6+9ho0kBS7HJ6y4cF9F3IpD6imKue9wGKU64sW6w== X-Received: by 2002:a5d:6d50:0:b0:306:2638:fa6c with SMTP id k16-20020a5d6d50000000b003062638fa6cmr4570750wri.33.1682943079890; Mon, 01 May 2023 05:11:19 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:19 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com, Wesley Cheng Subject: [PATCH v6 05/13] dt-bindings: usb: Add Qualcomm PMIC Type-C Date: Mon, 1 May 2023 13:11:03 +0100 Message-Id: <20230501121111.1058190-6-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Add a description for the Type-C silicon interface inside Qualcomm's PM8150b hardware block. Based on original work by Wesley. Signed-off-by: Wesley Cheng Signed-off-by: Bryan O'Donoghue --- .../bindings/usb/qcom,pmic-typec.yaml | 190 ++++++++++++++++++ 1 file changed, 190 insertions(+) create mode 100644 Documentation/devicetree/bindings/usb/qcom,pmic-typec.yaml diff --git a/Documentation/devicetree/bindings/usb/qcom,pmic-typec.yaml b/Documentation/devicetree/bindings/usb/qcom,pmic-typec.yaml new file mode 100644 index 0000000000000..17c5c244c1701 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/qcom,pmic-typec.yaml @@ -0,0 +1,190 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/qcom,pmic-typec.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm PMIC based USB Type-C block + +maintainers: + - Bryan O'Donoghue + +description: + Qualcomm PMIC Type-C block + +properties: + compatible: + enum: + - qcom,pm8150b-typec + + connector: + type: object + $ref: /schemas/connector/usb-connector.yaml# + unevaluatedProperties: false + + reg: + description: Type-C port and pdphy SPMI register base offsets + maxItems: 2 + + interrupts: + items: + - description: Type-C CC attach notification, VBUS error, tCCDebounce done + - description: Type-C VCONN powered + - description: Type-C CC state change + - description: Type-C VCONN over-current + - description: Type-C VBUS state change + - description: Type-C Attach/detach notification + - description: Type-C Legacy cable detect + - description: Type-C Try.Src Try.Snk state change + - description: Power Domain Signal TX - HardReset or CableReset signal TX + - description: Power Domain Signal RX - HardReset or CableReset signal RX + - description: Power Domain TX complete + - description: Power Domain RX complete + - description: Power Domain TX fail + - description: Power Domain TX message discard + - description: Power Domain RX message discard + - description: Power Domain Fast Role Swap event + + interrupt-names: + items: + - const: or-rid-detect-change + - const: vpd-detect + - const: cc-state-change + - const: vconn-oc + - const: vbus-change + - const: attach-detach + - const: legacy-cable-detect + - const: try-snk-src-detect + - const: sig-tx + - const: sig-rx + - const: msg-tx + - const: msg-rx + - const: msg-tx-failed + - const: msg-tx-discarded + - const: msg-rx-discarded + - const: fr-swap + + vdd-vbus-supply: + description: VBUS power supply. + + vdd-pdphy-supply: + description: VDD regulator supply to the PDPHY. + + port: + $ref: /schemas/graph.yaml#/properties/port + description: + Contains a port which produces data-role switching messages. + +required: + - compatible + - reg + - interrupts + - interrupt-names + - vdd-vbus-supply + - vdd-pdphy-supply + +additionalProperties: false + +examples: + - | + #include + #include + + pmic { + #address-cells = <1>; + #size-cells = <0>; + + pm8150b_typec: typec@1500 { + compatible = "qcom,pm8150b-typec"; + reg = <0x1500>, + <0x1700>; + + interrupts = <0x2 0x15 0x00 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x01 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x02 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x03 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x04 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x05 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x06 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x07 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x00 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x01 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x02 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x03 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x04 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x05 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x06 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x07 IRQ_TYPE_EDGE_RISING>; + + interrupt-names = "or-rid-detect-change", + "vpd-detect", + "cc-state-change", + "vconn-oc", + "vbus-change", + "attach-detach", + "legacy-cable-detect", + "try-snk-src-detect", + "sig-tx", + "sig-rx", + "msg-tx", + "msg-rx", + "msg-tx-failed", + "msg-tx-discarded", + "msg-rx-discarded", + "fr-swap"; + + vdd-vbus-supply = <&pm8150b_vbus>; + vdd-pdphy-supply = <&vreg_l2a_3p1>; + + connector { + compatible = "usb-c-connector"; + + power-role = "source"; + data-role = "dual"; + self-powered; + + source-pdos = ; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + pmic_typec_mux_out: endpoint { + remote-endpoint = <&usb_phy_typec_mux_in>; + }; + }; + + port@1 { + reg = <1>; + pmic_typec_role_switch_out: endpoint { + remote-endpoint = <&usb_controller_role_switch_in>; + }; + }; + }; + }; + }; + }; + + usb_controller { + dr_mode = "otg"; + usb-role-switch; + port { + usb_controller_role_switch_in: endpoint { + remote-endpoint = <&pmic_typec_role_switch_out>; + }; + }; + }; + + usb_phy { + orientation-switch; + port { + usb_phy_typec_mux_in: endpoint { + remote-endpoint = <&pmic_typec_mux_out>; + }; + }; + }; + +... From patchwork Mon May 1 12:11:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678337 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 B65B3C77B73 for ; Mon, 1 May 2023 12:11:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232511AbjEAML2 (ORCPT ); Mon, 1 May 2023 08:11:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47810 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232484AbjEAML0 (ORCPT ); Mon, 1 May 2023 08:11:26 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C7A18E5B for ; Mon, 1 May 2023 05:11:24 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-3f192c23fffso13276185e9.3 for ; Mon, 01 May 2023 05:11:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943083; x=1685535083; 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=1ezqUbWswfy2WUlCvIHmGIfKnDufe3ITp5T03UEYhmU=; b=POMHRx22ZyjBidz4o5r40oFFjfguQ/PxTXtz4TMnyFIZHOjVnUZ+S+WSREZfKKtbHC X5u7vvGbJXMns5zr3Lkh1s6qoGyE0TOgnxMbxWZq+ArgoJ6agY1kivZLgXPHPjaBrbaY Ewhau2trb8NBVgBYraCwGkzKheWnPW/ghLj83yjd5zGnDBCA6GedXjtS9k7a6bJ4TgL4 3uJKCf9nMZuhg+BZCMz19GfvOUpixGvTn8rC3qWnDZboy6nVecf1bwF3vlZx61rNoVIt IutbyBj9uLqr2SKGIYOzI4MCePIZcA1Rft/ysEb5YpCz8WHoVjCNgJPz2eL5bHmYyh4I 9+Xg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943083; x=1685535083; 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=1ezqUbWswfy2WUlCvIHmGIfKnDufe3ITp5T03UEYhmU=; b=gDpt4lf90dc5NJGXiCIPTyStV9X8uFBCCJ0F5aJTIqzJgOg4B8OF7jQGAyXMNgmgPY UyhVxNpBG7DpEHKGG2yvZYY9uqAets+4avKhoaelTowRFS/CRzitycpkruvU6KRlJ4A1 D9mf+acDQL5RpqWOZ66Mb9l0WHlJnydmm0U5KMs08Im65xUBhTmULC2WGJUqmQCQZ29m uEeMEc1nlF+aXyy+4MiUqsV/F2Mg5F0e1WhjHKJMVcAv+/ezpzuRiXAS3FyYtauqM8DZ zv3fm2NULTTRLbcumj6vXwcWcwdnENHcJkFXclGw38963JubVcYLQwfvpJNNd04tgI9u c/cQ== X-Gm-Message-State: AC+VfDyKiclQEnxkieNYVAli92vpTDbEDdTB3NF25GfF1jPNW+G5YZyN +HYOO5o8vQiIAJ+AMj9Jnkm94w== X-Google-Smtp-Source: ACHHUZ4zAKMyLl4g23cE4RgbAgw2i6h6YBK+eCmr3GXQgJ5n2fekXzqkTrZU0u8LGUzTFxK+CgKetQ== X-Received: by 2002:a05:600c:2318:b0:3f1:72ec:400d with SMTP id 24-20020a05600c231800b003f172ec400dmr9305390wmo.33.1682943083248; Mon, 01 May 2023 05:11:23 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:22 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v6 08/13] arm64: dts: qcom: sm8250: Define ports for qmpphy orientation-switching Date: Mon, 1 May 2023 13:11:06 +0100 Message-Id: <20230501121111.1058190-9-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org ports for orientation switching input and output. The individual board dts files will instantiate port@0 and port@1 depending on the supported feature-set. Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/sm8250.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi index a91d1175255e8..af16d3ba76b8e 100644 --- a/arch/arm64/boot/dts/qcom/sm8250.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi @@ -3581,6 +3581,19 @@ dp_phy: dp-phy@88ea200 { #phy-cells = <0>; #clock-cells = <1>; }; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + }; + + port@1 { + reg = <1>; + }; + }; }; usb_2_qmpphy: phy@88eb000 { From patchwork Mon May 1 12:11:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678336 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 B7C45C7EE21 for ; Mon, 1 May 2023 12:11:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232523AbjEAMLb (ORCPT ); Mon, 1 May 2023 08:11:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48032 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232504AbjEAML3 (ORCPT ); Mon, 1 May 2023 08:11:29 -0400 Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 08BB01727 for ; Mon, 1 May 2023 05:11:25 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-3f196e8e2c6so23829045e9.1 for ; Mon, 01 May 2023 05:11:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943084; x=1685535084; 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=zy2VqxQ0CXo4WaSyrIIsf6gNNOxqYn5NZo41bw1Nchg=; b=ouvSwWhnYGC18n0NRFidiAiGJ+6ghzXgtfNQ4k2MhmWSG2PLUoXabfqdCsp6ihvdCI FR7AUcdfks8qQldbMAT9+F6slQGwq8UrDXBOJ3p500n+7kMI8fMUPHVT8Uu1ylCTMblZ 1NrpUf79QfghBCgBnjRTDLDtalMdxEEwUx8eKhyXGNCJCueIaOrqTgFxxe5czBkl4GWl 0VaYJUGFkRyB/S74/44cMnU4jWXlsbaW/jrdTPdd+x1DZdt0Gymo365gkoXI0dNZOHLa DmriEckmBb7FSRCU5FW+yFjKaTrf3CXkxvdB3i2Ci4JsBmG3GNz9uPoozbjJQLUu6nYh eDHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943084; x=1685535084; 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=zy2VqxQ0CXo4WaSyrIIsf6gNNOxqYn5NZo41bw1Nchg=; b=Vtme5WPpI/hFSZd88qRlCnRMbvZrZ7x81wZfIxE6I/RN+sGO3GPdmNcgGUJx/yJOy4 uqFfXomMugH1CLxkD/MGzrWI2L9HbJKuPPZW/BFJfLDiW3duwzfkanefQlz/QcOtiWCe V5GGXq8s3YnyzkXA6tNZbZwMlD8I2FinQmSOFrlkfrYq+J0YWBYAk1m8zwIi2sGNWbPu PNb7J3c7k9QMZn53BVvUH+aQvhcYsE2F/IyWu86l4hTyZpwhdVY6DnPMdiHK02sXQJ5o ex8PszPePYElUtVg+i2/6EnaFX3f8gELXaOi/dEisfjBIya9FbTIqPvQTIhrwDGgfani +log== X-Gm-Message-State: AC+VfDypu1f71SQKbVAhSRSJF1TqyqBnSyRd+3aVqIgtbTHwA3Ub6ylF 6lMewo0URHeetFN6XyxZ+AnENg== X-Google-Smtp-Source: ACHHUZ4h5x0Q6CL+NXPB7tNpi34fW96boFO4YW66pOc8CmnebQl8b+VL1Z6/xJAlgWaVn/HuE6upOw== X-Received: by 2002:a05:600c:2212:b0:3f1:73c1:d1ad with SMTP id z18-20020a05600c221200b003f173c1d1admr9492510wml.35.1682943084368; Mon, 01 May 2023 05:11:24 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:23 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v6 09/13] arm64: dts: qcom: pm8150b: Add a TCPM description Date: Mon, 1 May 2023 13:11:07 +0100 Message-Id: <20230501121111.1058190-10-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Type-C port management functionality lives inside of the PMIC block on pm8150b. The Type-C port management logic controls orientation detection, vbus/vconn sense and to send/receive Type-C Power Domain messages. Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/pm8150b.dtsi | 40 +++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/pm8150b.dtsi b/arch/arm64/boot/dts/qcom/pm8150b.dtsi index 66752cc063d60..ffec8cfbd82a2 100644 --- a/arch/arm64/boot/dts/qcom/pm8150b.dtsi +++ b/arch/arm64/boot/dts/qcom/pm8150b.dtsi @@ -59,6 +59,46 @@ pm8150b_vbus: usb-vbus-regulator@1100 { reg = <0x1100>; }; + pm8150b_typec: typec@1500 { + compatible = "qcom,pm8150b-typec"; + reg = <0x1500>, + <0x1700>; + interrupts = <0x2 0x15 0x00 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x01 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x02 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x03 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x04 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x05 IRQ_TYPE_EDGE_RISING>, + <0x2 0x15 0x06 IRQ_TYPE_EDGE_BOTH>, + <0x2 0x15 0x07 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x00 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x01 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x02 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x03 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x04 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x05 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x06 IRQ_TYPE_EDGE_RISING>, + <0x2 0x17 0x07 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "or-rid-detect-change", + "vpd-detect", + "cc-state-change", + "vconn-oc", + "vbus-change", + "attach-detach", + "legacy-cable-detect", + "try-snk-src-detect", + "sig-tx", + "sig-rx", + "msg-tx", + "msg-rx", + "msg-tx-failed", + "msg-tx-discarded", + "msg-rx-discarded", + "fr-swap"; + vdd-pdphy-supply = <&vreg_l2a_3p1>; + vdd-vbus-supply = <&pm8150b_vbus>; + }; + pm8150b_temp: temp-alarm@2400 { compatible = "qcom,spmi-temp-alarm"; reg = <0x2400>; From patchwork Mon May 1 12:11:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678335 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 9BB45C7EE2A for ; Mon, 1 May 2023 12:11:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232540AbjEAMLf (ORCPT ); Mon, 1 May 2023 08:11:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48230 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232525AbjEAMLe (ORCPT ); Mon, 1 May 2023 08:11:34 -0400 Received: from mail-wm1-x332.google.com (mail-wm1-x332.google.com [IPv6:2a00:1450:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 493F81729 for ; Mon, 1 May 2023 05:11:29 -0700 (PDT) Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-3f09b4a1584so14026475e9.2 for ; Mon, 01 May 2023 05:11:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943087; x=1685535087; 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=ld1lJXBQF2mP2uTbXFQHQN+Mj3BbZpVpPgcFeLCv16E=; b=pdbqbjH7ipXYXKmVtsphxt9WuuUa4wG2VGFzgt0rgW8eW89RZYW9fjGbta7P12W8rt B27ZbBnTRuuCrgGULzqc+NwPMkKP4z9mPY0oq46jJy4HhhlRtMEP/4e9heuoDNUxsR3h Cu3Qx8ps19y5jQWc+7BkLUvAwqbwAFylJhaKXEMlNjLh972CpPj8ilx9S3GZg5kh0Cv2 NByeq9jy5jcL7poyg4veenYCkgD+IkxJ8UpwiwvxqhuKpawoM6J8jSW0k1aOqxYbWYVe i5ctqUV7NFjb0iPDouwfNyJpIsUjsH/7Tr2d1MTGepnlGVE+gK1cqCWFhmWGOaZu1pZz EtvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943087; x=1685535087; 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=ld1lJXBQF2mP2uTbXFQHQN+Mj3BbZpVpPgcFeLCv16E=; b=VHJKSfI3rQbGSCpVYX1P3Ayx5yVTeTA+e68yieRRMZSi5u1kMLyBdI4sQy/P8fh7IT vIaGaoL+NHRgqC0CeFKbtjoSBuZtI2QWgwmGShOf1Rqy91khnG4hXOy1Hn6pZNJAbBK3 mGy3njGWeoDPAcnQ35QrBEG9XDow/sHCoG1cmMgUJHCimWXF9Yxnj2uYPSBCvUeMFbl0 B1pyMIoVcPAKQhT/OH9uW/oulxnLLza5KwL2z65alF1o3CzK61ses8KJtQfxc+/Wz/fa dAnogI25XmyCBVRhHBgVUNOn/XoRMzDSPjEnutNPWQyOs44tBQ4t+NlHNNHkmfi0BSkM weDw== X-Gm-Message-State: AC+VfDwpA4X54+7XKbkfDyUiAi0MS74WNGikw9uE8bGD0uhujjooknm+ YmRrA/zsriB5U4/SMTp4D+YZDA== X-Google-Smtp-Source: ACHHUZ4TXtmc8ACU/flHPI2yHzYlfetC4dY3+slyL6ZiFnTzsktAU221bdWqI8RTPoOAOtqieRTfAA== X-Received: by 2002:a05:600c:d7:b0:3f1:93c2:4df6 with SMTP id u23-20020a05600c00d700b003f193c24df6mr9254248wmm.12.1682943087414; Mon, 01 May 2023 05:11:27 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:27 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v6 11/13] arm64: dts: qcom: qrb5165-rb5: Switch on basic TCPM Date: Mon, 1 May 2023 13:11:09 +0100 Message-Id: <20230501121111.1058190-12-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Switch on TCPM for the RB5. Here we declare as a source only not a sink since qrb5165 doesn't support powering exclusively from the type-c port. Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index b326bdeeb7742..1e0b6fd59abc9 100644 --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts @@ -9,6 +9,7 @@ #include #include #include +#include #include "sm8250.dtsi" #include "pm8150.dtsi" #include "pm8150b.dtsi" @@ -1344,3 +1345,19 @@ &pm8150b_vbus { regulator-max-microamp = <3000000>; status = "okay"; }; + +&pm8150b_typec { + status = "okay"; + connector { + compatible = "usb-c-connector"; + + power-role = "source"; + data-role = "dual"; + self-powered; + + source-pdos = ; + }; +}; From patchwork Mon May 1 12:11:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 678334 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 18912C7EE21 for ; Mon, 1 May 2023 12:11:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232544AbjEAMLk (ORCPT ); Mon, 1 May 2023 08:11:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48408 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232548AbjEAMLi (ORCPT ); Mon, 1 May 2023 08:11:38 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3E641701 for ; Mon, 1 May 2023 05:11:30 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-3f1950f5676so25386865e9.3 for ; Mon, 01 May 2023 05:11:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1682943089; x=1685535089; 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=zcMNU2pXY7at0soUmicgwVM/bFPgaN3uZsi3VUVpjYA=; b=AwWEzSRkWUIDRrxEH1u7BILJWZieTXOPsUY7V3LKbeJfxJsThda59xWNyCNZ8Txgih rIFv/hOxn2wNVk1YC6tGZHnoKmx6OwLm9+n0+sR5XP+8Txw7CXVUXeHYaXLwbWSeihtf nxJehKCmI1NsOGp+hPPgEEHB8kEpj9yxhJDq9Gp1mFkO6tEG+Uqv2hTDvxaWJQW9K2I7 yuTJ8djXTVFoA7sKYC+MQKL0ADPsFS/9vSyLai69QJk2FoO2BDJ1bnihL7lOtZNbyllN zkxTfegLzVwICXPX4k0cdt8LVNsv6Zo43Pv2H7yLO2MjecKivqsQCVNWM7sLAFgIa42B mO0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682943089; x=1685535089; 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=zcMNU2pXY7at0soUmicgwVM/bFPgaN3uZsi3VUVpjYA=; b=NPlCQ8xrDJCe+8cT1ViqTU0qhShoblYqT923GYrsa1f7TqtoZBxV+fwvG3P0MvVsB1 jft6oIJdjY95ZpbFZ72NCRkoq1fzWtpsLDVokvTXJnAWjc7PXCGqSsvTo4PepkJp/eLv JQV5JMDw68/QBUinNKIkqKAqBtMfxF7wBAujP9Rpdy+yNKOmuQ74Jc2ORH4I4YKJQALq GbJuqODNexwsMedAwxFv9bsNMcncEqtnJDGuTo2mgdx3gA2yUcFLYfQyaWRjl1ZJrduI YqKxR3bywZfk0VZpOUxxre+1Ete5lklcv1pnOaC+8jm9dMycW9F9uEgbDtQKTigLY6Dn uScA== X-Gm-Message-State: AC+VfDyOHbtKBy4LRl65EaKo8i9c/NvPEhjfiHQMN8UPRTwv0Jd2kR0O 1LRb4KiptYHr0lDS9ZUjPJ+pFg== X-Google-Smtp-Source: ACHHUZ5evhvGogRq7WoYPYxGULCGHYzaLMxYpC3XUQvheYzH8fgrkIk5K58WTWPDmH0RDs/0wX6JdQ== X-Received: by 2002:a05:600c:210b:b0:3f1:8b0f:96ea with SMTP id u11-20020a05600c210b00b003f18b0f96eamr9021436wml.37.1682943089508; Mon, 01 May 2023 05:11:29 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id o10-20020a05600c510a00b003ee443bf0c7sm35856634wms.16.2023.05.01.05.11.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 05:11:29 -0700 (PDT) From: Bryan O'Donoghue To: linux@roeck-us.net, heikki.krogerus@linux.intel.com, gregkh@linuxfoundation.org, andersson@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, luca.weiss@fairphone.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, konrad.dybcio@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v6 13/13] arm64: dts: qcom: qrb5165-rb5: Switch on TCPM orientation-switch for usb_1_qmpphy Date: Mon, 1 May 2023 13:11:11 +0100 Message-Id: <20230501121111.1058190-14-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> References: <20230501121111.1058190-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Switch on USB orientation-switching for usb_1_qmp via TCPM. Detecting the orientation switch is required to get the PHY to reset and bring-up the PHY with the CC lines set to the appropriate lane. Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index b5cc45358a474..8935a8e327904 100644 --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts @@ -1295,6 +1295,14 @@ &usb_1_qmpphy { vdda-phy-supply = <&vreg_l9a_1p2>; vdda-pll-supply = <&vreg_l18a_0p92>; + orientation-switch; + ports { + port@1 { + qmpphy_typec_mux_in: endpoint { + remote-endpoint = <&pm8150b_typec_mux_out>; + }; + }; + }; }; &usb_2 { @@ -1375,6 +1383,12 @@ pm8150b_role_switch_out: endpoint { remote-endpoint = <&dwc3_role_switch_in>; }; }; + port@1 { + reg = <1>; + pm8150b_typec_mux_out: endpoint { + remote-endpoint = <&qmpphy_typec_mux_in>; + }; + }; }; }; };