From patchwork Mon May 8 14:22:56 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: 679946 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 1E321C77B75 for ; Mon, 8 May 2023 14:23:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234556AbjEHOX0 (ORCPT ); Mon, 8 May 2023 10:23:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59232 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231641AbjEHOXZ (ORCPT ); Mon, 8 May 2023 10:23:25 -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 D50EF3AB5 for ; Mon, 8 May 2023 07:23:20 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-3f4000ec71dso30617385e9.2 for ; Mon, 08 May 2023 07:23:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555799; x=1686147799; 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=gdPOb/kVKRm2CWLAaTiuZb0Yvx8fGBpCags1edg/orY=; b=yIBHKDr9ml1J2JcqNoaWW7WrzMFuA9l8xBp6pK2Ix/vQOqi43fpjss3oEUpgmoYWVP MpZZ9+LGV5oP64MTmToAiznCGOZdX7UuoXw81rli8Gqs5YoQZcuhIgHc7zvg+r35i2sZ BAGmYP+tBlftcOsyy4GNNEsfzRNaqycPZwFGQtTc/urJZxRDMomCBAZufgXmtdENAYyc 7VmJ90x2HoYwxed+ux2sYLFmdhoBEMDDV7SFQkt1xcx9MfJwPopPRf8J2q5o3MBIbwVW vLJ0aCWOKdVZKNB14enAtyn0LnQeLzLq2p9XC64ukDroLKDbvrLMsPjfSaRnfMJtUGQY F+iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555799; x=1686147799; 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=gdPOb/kVKRm2CWLAaTiuZb0Yvx8fGBpCags1edg/orY=; b=OSrDnszNyYHlBTBhqqJ+mRjZLDEGi1fl+SpYwM6ih5pXhjZH6R1iw/n89rtAa2HbRH 2NjjqdCDV/dTcOAn21ysmYbQm+X89CeUiGAdNZ+djfyImmQYeR+az8WD9WR0o+kLBCZ+ q7H1atjlXn9DhsgYFkv7yb7mAJNz8BibeUPRz1T4MBYiuerEyr0iNhnvGYFjv2bl87/C EUJC5pzx/YK0ikTJDTFNaOGaLJ6LwEdA5IygnbsScoCdOEqLqIy49GcwUnLPlJDN6TXY CJU1KcK6d6cyMWJRgDZAbE8ep8NlH6pxUIIGZsoqjc+xUAryqIUd8slA8dUl0Fo/7Iom EUeQ== X-Gm-Message-State: AC+VfDzZ4ksYFxS6tsBFTZ6vjuhN956XfF1CwbqxgFTm5Tgdst14tmvT 4TjtJj8jZtZGj9BKbpS3QD9FwQ== X-Google-Smtp-Source: ACHHUZ5hq0SyhyQa9Ak/eEutefcC6/24ACvPJHsagmiW4oPSiIw3HdOpMRl3hXIYd5TIKv6cUNvyKQ== X-Received: by 2002:a05:600c:2317:b0:3f1:76d4:d43f with SMTP id 23-20020a05600c231700b003f176d4d43fmr7146344wmo.8.1683555799260; Mon, 08 May 2023 07:23: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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:18 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com, Krzysztof Kozlowski Subject: [PATCH v7 01/13] dt-bindings: regulator: qcom,usb-vbus-regulator: Mark reg as required Date: Mon, 8 May 2023 15:22:56 +0100 Message-Id: <20230508142308.1656410-2-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The regulator code needs to know the location of the register to write to to switch on/off. Right now we have a driver that does this, a yaml that partially describes it and no dts that uses it. Switching on the VBUS for sm8250 shows that we haven't documented reg as a required property, do so now. Acked-by: Krzysztof Kozlowski Signed-off-by: Bryan O'Donoghue --- .../devicetree/bindings/regulator/qcom,usb-vbus-regulator.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/regulator/qcom,usb-vbus-regulator.yaml b/Documentation/devicetree/bindings/regulator/qcom,usb-vbus-regulator.yaml index b1cff3adb21b5..7a3b59f836092 100644 --- a/Documentation/devicetree/bindings/regulator/qcom,usb-vbus-regulator.yaml +++ b/Documentation/devicetree/bindings/regulator/qcom,usb-vbus-regulator.yaml @@ -25,6 +25,7 @@ properties: required: - compatible + - reg additionalProperties: false From patchwork Mon May 8 14:22:58 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: 679945 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 CF73BC77B7F for ; Mon, 8 May 2023 14:23:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233588AbjEHOX2 (ORCPT ); Mon, 8 May 2023 10:23:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234548AbjEHOX1 (ORCPT ); Mon, 8 May 2023 10:23:27 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C3A01FF6 for ; Mon, 8 May 2023 07:23:23 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-3f19afc4fd8so29099325e9.2 for ; Mon, 08 May 2023 07:23:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555802; x=1686147802; 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=I/27knbkC+8cyh09EvxDxcYg5VSh/Z9C+EWY4oze5Ute3pGEkX3M3nUXzBHTai6xSg uqh1XOzpMZCyY2ugyTa/BjUExjJdYlG9wiD9knGziGZmfmuF3aCBaQ8BC2/dUWhJq6MJ GwAnRuB5SQ/Ie8b3aRSvG8ZwB2t1n2p9khF7fTsk+6EHl3tOst7Mx0YW+wEQ/VeJ/t5A zeyDM/hsXwfWErXKnsMvdhT9yisEIXExqDXh9N1EPbjn0d7LhGBU3LYWJU2AqpywJCHy 4Ly6HiXtXoB5xao/fIUkX6kj7GsJZXosyPEq3HWxJLc9tr9Gfi62f6IC8xzXd2AFi+/u mPfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555802; x=1686147802; 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=lv4IOboOi+8dRICDjxqrS4spQWsEds0pfR9AqT+p0Z++eWk4mwotJcYYpJL878DC8y 1oOj9qF0aQTNimHqqGkeflYuBtNfO8POs5ILhIWpTgPU+MxBa1SvRcRXF1/JM0r1W1O9 27u9vUfQxqCZ7hf8S70ad+G/bbUjw/YY5m4iiTQpTpsikU0vUI83xHJpaxF6x50oTIy3 5P9s3PBwMj/5NR33UOvJgsmSw9OtbUcDVBqrxVcghk5Rg5nl37F9nxZzuBJhDGZ1tbw4 gI+g5tmrlpjmCEk92RFymQrqtbenvyg01JZApkWqpYKQGKYJq9o8OCgfkF+9oEdsyHMy 9OqA== X-Gm-Message-State: AC+VfDxfQefVB6f5rZBHwjnQ+15M4O8zQDeRNrxz4nkQlwWFfLnmgb5y 7cL/tGGS0kPoMBauduiNh8crDQ== X-Google-Smtp-Source: ACHHUZ6u4+NYFZLp7vzZNTbrYZeZr+T2vFz6juAgBQ97Y4NJ320G2xqBHa/usyck+Pz+8zOSPnyByw== X-Received: by 2002:a1c:7519:0:b0:3f4:2452:9666 with SMTP id o25-20020a1c7519000000b003f424529666mr2554114wmc.40.1683555801905; Mon, 08 May 2023 07:23:21 -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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:21 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com, Krzysztof Kozlowski Subject: [PATCH v7 03/13] dt-bindings: phy: qcom,sc7180-qmp-usb3-dp-phy: Add orientation-switch as optional Date: Mon, 8 May 2023 15:22:58 +0100 Message-Id: <20230508142308.1656410-4-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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 8 14:23:00 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: 679944 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 05D3EC77B75 for ; Mon, 8 May 2023 14:23:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233471AbjEHOXb (ORCPT ); Mon, 8 May 2023 10:23:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233870AbjEHOXa (ORCPT ); Mon, 8 May 2023 10:23:30 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1ABBB1BD8 for ; Mon, 8 May 2023 07:23:26 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3f4000ec71dso30618165e9.2 for ; Mon, 08 May 2023 07:23:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555804; x=1686147804; 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=3oIx/YOLzSm+eiNVRyxGbhFkd6n9hgzPbuCkSewwSeo=; b=lnCwCq87XPSgFh7byB6nfDVrw1QBlsfxHnqMnikJBWXftT+hsDu801yZh6CvbfQHE2 dziKG5BEMK+4gEVAOokR7bS26iGYdI6Ykz40wPZ5q2Wukg00XD/eOR6ZKxjWPQ/z7EjC COnVWIEt6LnZz5w0pTK86INIrkyCa72kCnAxKJqA1zfOqR1wUY7EZW+PU5hwf9rJJhM8 WTsGDqIaAiQlcclyiZUp12vtEoc2CfELyJTvzKtvZ2DVB4M0t1GWl85mXqj/GSbMef8D 0haZTHVnh+/F6rrrgQY/vZ/Iv7wl7LHwoQxKkMc6jjk0LctAgOEvIUghGlAPnyB8+Zle A+fQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555804; x=1686147804; 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=3oIx/YOLzSm+eiNVRyxGbhFkd6n9hgzPbuCkSewwSeo=; b=aSyxytPg9knefZhz4+xbxY4a4f8xvmgdB/3T78NqsxTL3jbdEZBcdd9awYj0+YHBKu TpjYD7l1UZIbPsHkTO6QTvrpLij8Fp8NlAZ02pWnGUvX37Sspt3Zx0gNztQ0PxOZSgEl O/d3ZDE3hIeAjUpyx4SfDd3rF6ZJPScg1mGH4Ygo8/TDua6jKObOWi+M1syPvh697kNy tWqIBQ4V7KQ+2qh8avWpXwu516olhL+iC7kv5mnMEj5CSKtUrEHMBhLIxZAqkEJg+bUV gqnTb/nDSM4P8Y/wzbxNhcLz0ZOvGA5zKRWkvLuBqr727vAgVMSGninSUOrLl1/eaL9B qOiw== X-Gm-Message-State: AC+VfDx8JE87RyVNY7/CGxArgB0NsyJOnQVmmX5ekImpa+axXdx9OpS/ nAUJERt1YKZRMU/7qTTaFxzynA== X-Google-Smtp-Source: ACHHUZ59fjhFuwsN+1tesyFgb9pAM2X0g9QnwLHnlbs6lSJLD0pc9aElu0uSauVicOZrW+zep5QU+w== X-Received: by 2002:a05:600c:cf:b0:3f4:29c2:1cd0 with SMTP id u15-20020a05600c00cf00b003f429c21cd0mr46172wmm.25.1683555804559; Mon, 08 May 2023 07:23: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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:24 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com, Krzysztof Kozlowski , Wesley Cheng Subject: [PATCH v7 05/13] dt-bindings: usb: Add Qualcomm PMIC Type-C Date: Mon, 8 May 2023 15:23:00 +0100 Message-Id: <20230508142308.1656410-6-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add a description for the Type-C silicon interface inside Qualcomm's PM8150b hardware block. Based on original work by Wesley. Reviewed-by: Krzysztof Kozlowski 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..55df3129a0bc7 --- /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_role_switch_in>; + }; + }; + }; + }; + }; + }; + + usb { + dr_mode = "otg"; + usb-role-switch; + port { + usb_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 8 14:23: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: 679943 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 01220C7EE22 for ; Mon, 8 May 2023 14:23:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234585AbjEHOXh (ORCPT ); Mon, 8 May 2023 10:23:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59780 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234571AbjEHOXg (ORCPT ); Mon, 8 May 2023 10:23:36 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BDF13C27 for ; Mon, 8 May 2023 07:23:30 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-3f195b164c4so30213445e9.1 for ; Mon, 08 May 2023 07:23:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555809; x=1686147809; 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=nOwO+f9dgoCq7yiaazJXQ6WqCRqep8/4128RgQMh2rI=; b=GMR4MQjkOK7jR3sEC5AxXVMsIAHSRRXlbC4hsfhmrqU7rgRbbZqp8K4JS2PzyoXkyz eyPibNVAfTmJFgu7hbgGFtNOK4Vs7VrCosln4huhksuWC/0fdmEg1k4NsPIdcDPz/w5B tMqHfg2ryERBC/4qobBXLj8vtvva53+TFGKrsxXGDiUNVi9UhTi4aWpiNAjoEqnWIpo/ CkPhO930PgCupmRiAppBht3ScLFDSfZe0hleii8wGa0/XzsxGnhO4NHLN3vusjg8BXVe Lt1kgijyMUxLrVtQfQbu2XSP/KIa4YpmlSv2MYuuMSemzBikVD8l2mFRoGpyWdUi8wS0 YVsw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555809; x=1686147809; 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=nOwO+f9dgoCq7yiaazJXQ6WqCRqep8/4128RgQMh2rI=; b=AeNtuMUAObWaicsRY8TvKc1813kbMmjchQGCFIhDImxWgjFNuxeGJyjMlxbqZRqr9r AmDQaZm/BT7AgDXwDJygD/b3quxudeJ+LHuxVT6wXcxrrbDZiXextZMM34w/dfm0qSbk 1j5QtqmNL1t+3yix6vsaMxE2vQ/+ZTxWiYSzm292jezUGn7SYiy9aGKLRlxDoJB7igr/ Iw7SmSxNZ2qC+xEixTjhDzSQa6dZ/duTJXnHKcSXp2sfBF5LW6rYh3Yr/6P4/uVPwG5z jGW8nMABcY6+4OCZciinRlJdJRtQL2mByeaH/yKWD+pF0i5ewMZx8WxNOjuS0rfOO88z kFOQ== X-Gm-Message-State: AC+VfDxk7OoJVLlOd1jQ3dyRDqZQ9Tj3q+sZTxK7EPXH7hIQdmrdLIe3 mjg6I5Cwk4v3r3l/a2EnqFSTMw== X-Google-Smtp-Source: ACHHUZ52nZBEIBxWuVVwYem0TqBeYXBoVhKITScVR5R3kZrvcWiCeorF7qp0rb+Nyo4RnpiNhCJJoQ== X-Received: by 2002:a7b:ca4c:0:b0:3f4:2819:7777 with SMTP id m12-20020a7bca4c000000b003f428197777mr1149158wml.38.1683555808809; Mon, 08 May 2023 07:23:28 -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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23: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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v7 08/13] arm64: dts: qcom: sm8250: Define ports for qmpphy orientation-switching Date: Mon, 8 May 2023 15:23:03 +0100 Message-Id: <20230508142308.1656410-9-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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. Reviewed-by: Konrad Dybcio 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 8 14:23:05 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: 679942 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 3F471C7EE30 for ; Mon, 8 May 2023 14:23:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234501AbjEHOXk (ORCPT ); Mon, 8 May 2023 10:23:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59780 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233973AbjEHOXj (ORCPT ); Mon, 8 May 2023 10:23:39 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EF87472A9 for ; Mon, 8 May 2023 07:23:33 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3f415a9015bso26187805e9.2 for ; Mon, 08 May 2023 07:23:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555812; x=1686147812; 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=CuPqCRZb0IOEal0w8tbJWxx13wX54OyCGod52wMQWCk=; b=L095LF8R92NW0DNcTNK8xuw5TTo47xr5DJhu9QjB42R3KemLKRrJSlKGdxk8ZOy3Tm W8NfddmrEptWsjN+rnpD2xjKdu6Aaz31D74JGmq0nSir9qfuph0SxyJTWjTlnP5XZyOz 84i4qTQiW2osU5rlgt0KhnPX6MaDlZKm+Ba9OQZdpRDXJU1Pw4Aaz792ywi8NN1A30ON 5gLD6JtPbaYMpxoU3V1zcxgY/1YMJGNUPO40N8P/WayJBNS9AOjYFQYnp+oOJUFMe3M6 aZ/UszyZvUvjPriE4hNQmizdLoC4mz7Xs2rkE+hlpWB4xWs7kSj2iO1AcLkVv/mr8cYI gOSg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555812; x=1686147812; 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=CuPqCRZb0IOEal0w8tbJWxx13wX54OyCGod52wMQWCk=; b=Qj7j7bPRcxIOZTLH+oaQFsD/uYVhpgTuuJAPCWRKBgWgxp7Oa/r0cq45y5ZLxEyqtO JeqwthTKvpjJ2pJYpqtNZJ+BcS0ybtqdom7sh2/38qI14pFw2GOiXYRz/VzWv19yavl6 SqWXsR/lBrWwHcAcyeIKuBuvVSDCB1KSJLj4mUf5MrniORokMBIuOW6pHgMx1YTDgJpa p5jlDssic5sqsUjAHAjxG7p2zsAOWfTWCCPqI9sMiLxUA5/+SIaA56UyY0tKhm3oNTi2 6lcPBBoNIHN6Q8MGqk7f80AtMVZNzjzJFmRoTVBF+fhFOapOGgFylgng1OWUD4I9E0Um 5YdA== X-Gm-Message-State: AC+VfDysdGHf2z6K5d/fJMcMb1worhR8v3Cyr8gzaRWC8HuEU15demVx BVwh0CKnKk9VsJ6gmTkrRpxgAQ== X-Google-Smtp-Source: ACHHUZ5Ta2Cw6d4nfqlsLV6srThJ8dTvJh/B+AlkW5yMFrvJalADUwbb90ib3hQChWCGN1p+zPaAEA== X-Received: by 2002:a05:600c:2056:b0:3f4:1188:94ee with SMTP id p22-20020a05600c205600b003f4118894eemr6799013wmg.40.1683555812238; Mon, 08 May 2023 07:23:32 -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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:30 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v7 10/13] arm64: dts: qcom: qrb5165-rb5: Switch on Type-C VBUS boost Date: Mon, 8 May 2023 15:23:05 +0100 Message-Id: <20230508142308.1656410-11-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Switch on VBUS for the Type-C port. We need to support a higher amperage than the bootloader set 2 Amps. Reviewed-by: Konrad Dybcio Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index dd924331b0eea..b326bdeeb7742 100644 --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts @@ -1338,3 +1338,9 @@ &qup_spi0_data_clk { drive-strength = <6>; bias-disable; }; + +&pm8150b_vbus { + regulator-min-microamp = <500000>; + regulator-max-microamp = <3000000>; + status = "okay"; +}; From patchwork Mon May 8 14:23: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: 679941 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 4A796C7EE22 for ; Mon, 8 May 2023 14:23:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234590AbjEHOXm (ORCPT ); Mon, 8 May 2023 10:23:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59948 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234597AbjEHOXl (ORCPT ); Mon, 8 May 2023 10:23:41 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 379E57A80 for ; Mon, 8 May 2023 07:23:34 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-3f415a9015bso26188235e9.2 for ; Mon, 08 May 2023 07:23:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555813; x=1686147813; 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=FG5tzR489Q5zuHE05830FTIX4PfCR2BAkKIO8oRz4PM=; b=pwsEK1RexxSKooPrJV7NvaSFYw32hWGFFHQghHEQsOKeyvrFpIPpQsmVgqIlX962KU LCarTJPd1onYmqiWSPpObQZCuoAiqHBDP3/WdT4xuYECYJj8TC1Gu7zQatcb+3WFpYJb h1nJ26cSjaZBH5OoJ33m6+xq9Nzl1ApExlmR7y1wANMu9kY1iuq2iYZThex7aekwcn+p WRb9wlaTG35q8qlM8dEebh+yPZ4i9azA70oAuZPuvR1YSIHSOsW4D7cHc9jzJV+sAMrl u/Kvd1T51DTj7aE6hyDn8Z74Gd0/drnxIiWXM4ZQrRf4CO4QcG3NJOxFLZ/A0Inq7Hu3 DaIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555813; x=1686147813; 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=FG5tzR489Q5zuHE05830FTIX4PfCR2BAkKIO8oRz4PM=; b=jULIeTESFbXBwMO9UHtIsDfIKPIGaj0gKNcNre1IoVsEGq/Y7L8T3yXW4RZlvZ4giQ uRDPx/AZDru334ydFbmKyOp5E/3JTHF3VRZ7ZRT6gmI95btKI2+azkbS6T9FAxT4rMrV plOY/E/B+ZZxsJ2i6o9bQ1gVXRiJHywHM0dopglMIitipYtpHhKYtP1XvbonsSE8NVzP IflDYAjgVFvsZdSUwiVvp6xJ9LEXbmzu6l+w7OLnspnVUboOGkYvTzTqDNIl4bE7zwXk ObLTqWUGIz92hqVj2FjCpMLUQCAJ0KOuxAjNhRa0pbtkJ5sAd2QCUf5xdhfBbCKl7jgU 5wWg== X-Gm-Message-State: AC+VfDx7W4rp0YzewXRB2DyQvNrU6YaigzTdb2Gio5Hylwpza/cDVkbN r4HlajeBHaEKLzY4PB/i4tVtbg== X-Google-Smtp-Source: ACHHUZ66vbFSmzx7Vv2ZmMD7T7KdPSK8tRKyRDjcHUYLGvxL28gBIcU4HQvr6Udc+x7CsJZTXO6eKw== X-Received: by 2002:a7b:c4c3:0:b0:3f1:9526:22d4 with SMTP id g3-20020a7bc4c3000000b003f1952622d4mr7302662wmk.21.1683555813601; Mon, 08 May 2023 07:23:33 -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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:33 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v7 11/13] arm64: dts: qcom: qrb5165-rb5: Switch on basic TCPM Date: Mon, 8 May 2023 15:23:06 +0100 Message-Id: <20230508142308.1656410-12-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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. Reviewed-by: Konrad Dybcio Signed-off-by: Bryan O'Donoghue --- arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index b326bdeeb7742..df7179c7a58f3 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,20 @@ &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 8 14:23:08 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: 679940 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 12834C77B7F for ; Mon, 8 May 2023 14:24:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234606AbjEHOX7 (ORCPT ); Mon, 8 May 2023 10:23:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60232 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234591AbjEHOX6 (ORCPT ); Mon, 8 May 2023 10:23:58 -0400 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E21662D74 for ; Mon, 8 May 2023 07:23:50 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-3f192c23fffso30185635e9.3 for ; Mon, 08 May 2023 07:23:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683555816; x=1686147816; 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=6epDoREeyW7xiYpBIh+9OmW/8MwkayI69pNElj0rHko=; b=npeYlGIXEpZf1feJ6JsnaYPH5yx6gv4uJQsVxnQiU1Dx/dgmfF3/NYaOmVv+/99mn5 EuDL8zfDWvy5inU0rhs6N1NO7B3idhd1EiMihMmoYo9Bhy70K/UGBgEYRK92oxBIdpf8 wAyDLQcooDvyjP10LZ4CYcehP+3+tbJ6/R+reHTn+0MfstK7cCOYJRZcn1kDBXeBn01t pjxqLvxJROuuqHn7gaTV6irF1qPk186pocjS/8hPsueq/kBJN5qlFXc5UQIuOtmoB6m5 uE9K4EkCaYfS+vJ5yiwMEXFXesekkZFdeLK+FoJ/I/zuF4ZmgGauDowC0qZR0jrQNX+8 P7xg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683555816; x=1686147816; 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=6epDoREeyW7xiYpBIh+9OmW/8MwkayI69pNElj0rHko=; b=d1TB9+YocsTQ9hvYW/QvsZwNgQeEAa3PxZVIEN9SrTM0IDbdCki0eYyP7dHhTKxuvR +Y1wTn7NnAInzZfwH4ipd0WlUIJcOjIS289CwLKfYsAM2O2ZEprvvD+7M9fic+5WjaVz 9Y/dVDX2aEZHJOuYuzzYnOY/65uv7jmzgHESbJFcAArdbVi070HaGydyCP2sxRYgqWai 3+KjXyDnKrDCtSt4Sib7u3Vqf3j1mnGKJPhcDEENw2PkPDGw7rtPLDa2K3Ati498DM1K u1zBVewW0FQCD1uqzQw/nunNSZ5FgQqWzf4mmZp8dZWOIZ3risuPSRT0symFaX7s79hY 7oPg== X-Gm-Message-State: AC+VfDwehwwnKg8FPMWzNRyZc1lTII/vmKFqhLQes+MKAcedd1/VrdUs sRnxh9RzDsYWV91VisAPbRQFiH0GHbmzwufbccf4Rw== X-Google-Smtp-Source: ACHHUZ5HrOPi4Zh1EtE+UopHE3YIu0K/UpyHlxZ8n6MukD06Vdr+QFlp2AagNqa9j3E1587ccsbtGg== X-Received: by 2002:a1c:f715:0:b0:3f1:6fe2:c4b2 with SMTP id v21-20020a1cf715000000b003f16fe2c4b2mr6992686wmh.23.1683555816729; Mon, 08 May 2023 07:23:36 -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 y25-20020a05600c365900b003f42456c490sm4081544wmq.33.2023.05.08.07.23.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 07:23:36 -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, lujianhua000@gmail.com, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org Cc: konrad.dybcio@linaro.org, caleb.connolly@linaro.org, bryan.odonoghue@linaro.org, subbaram@quicinc.com, jackp@quicinc.com, robertom@qti.qualcomm.com Subject: [PATCH v7 13/13] arm64: dts: qcom: qrb5165-rb5: Switch on TCPM orientation-switch for usb_1_qmpphy Date: Mon, 8 May 2023 15:23:08 +0100 Message-Id: <20230508142308.1656410-14-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> References: <20230508142308.1656410-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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 | 11 +++++++++++ arch/arm64/boot/dts/qcom/sm8250.dtsi | 1 + 2 files changed, 12 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index 286bf63caedd1..f522a48547472 100644 --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts @@ -1294,6 +1294,11 @@ &usb_1_qmpphy { vdda-phy-supply = <&vreg_l9a_1p2>; vdda-pll-supply = <&vreg_l18a_0p92>; + orientation-switch; +}; + +&usb_1_qmpphy_typec_mux_in { + remote-endpoint = <&pm8150b_typec_mux_out>; }; &usb_2 { @@ -1376,6 +1381,12 @@ pm8150b_role_switch_out: endpoint { remote-endpoint = <&usb_1_dwc3_role_switch_in>; }; }; + port@1 { + reg = <1>; + pm8150b_typec_mux_out: endpoint { + remote-endpoint = <&usb_1_qmpphy_typec_mux_in>; + }; + }; }; }; }; diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi index 3d79110892298..0ffca1bd217f7 100644 --- a/arch/arm64/boot/dts/qcom/sm8250.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi @@ -3588,6 +3588,7 @@ ports { port@0 { reg = <0>; + usb_1_qmpphy_typec_mux_in: endpoint {}; }; port@1 {