From patchwork Fri Mar 17 15:04:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 664598 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 6D76AC74A5B for ; Fri, 17 Mar 2023 15:04:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231374AbjCQPEb (ORCPT ); Fri, 17 Mar 2023 11:04:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230346AbjCQPE3 (ORCPT ); Fri, 17 Mar 2023 11:04:29 -0400 Received: from mail-wr1-x42b.google.com (mail-wr1-x42b.google.com [IPv6:2a00:1450:4864:20::42b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DD05910EA8C for ; Fri, 17 Mar 2023 08:04:26 -0700 (PDT) Received: by mail-wr1-x42b.google.com with SMTP id l12so4710639wrm.10 for ; Fri, 17 Mar 2023 08:04:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679065465; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:from:to:cc:subject:date:message-id:reply-to; bh=OrNP2U1Bweu+K3EQ1iwfmC2BkNeHceAtfpVaftw7AuE=; b=hvQ9L9xFlFTyzCzkELWRsbNWD+V8o/O/lxqs+ucNSpUnQCUbD4d8r54Yq/mXFbtfVW CVptaCLb5Z6AfEPH/1A9wosw0+a/8kAj/xJtSv2aW310M1fPWI2sRCnzmRKL8nrGmwtL YfBaZ5ssF1eohRIslE/uV7l7pXKDUNpE7QAMPCjCCl+6pvSnSJtQ8+YvND6kXfKv8WFC QxRou1r8QnlE0BezkH1j7GB8Va3IPzCnZl+67tvKgFzyLuPXu5G5osHiuvYSyUTS+DIt CBsX1LalRYayX/7RnNL9fWovxBE0w/k2hyVFEH3YDmAUm2gGRLH0AfRXJrO60YIepm04 UoKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679065465; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=OrNP2U1Bweu+K3EQ1iwfmC2BkNeHceAtfpVaftw7AuE=; b=KQBxN8w3vdMilGXNe2pAMMWlcCJCRdk5UJde1bPlGjNNE0JiReXvMtqfzz1+v1/kdR 7xP11taEFO/K/jduZa8fmpJrerRvUkNi822I1qPVjLPaidwBg6NraM/aaniojMKPIHBG tBI1fMUvTGoAqzN4q06zyHB456wRca4p5ujV8psTlGu/hxH5nYn0QgO25p8J/npET9TL 9VghGri4w7oBIskg64jtpo+h9OlAO55iAbMCATeRPcnr1JsvRzEipf8humSjse/9nknN oapLPqO9yJaVx8iTnITYfEC65RE3LMur0ydA7ec6fNKYd/SMAXrsWv58G44WvQ9HtAyY qh5g== X-Gm-Message-State: AO0yUKXmUVgjm7+oCajmcIjF+fGxb3Yfa0xU8xkFu7z/xDZL2yg/3l8A QCsHq9qhm2be8dZg5KIstAPz+g== X-Google-Smtp-Source: AK7set/6E/+aRE8WDx7crNSpQvDpdkFOTSvxHwHopJFuVaKrIh1NXS6C77sCNGCYq4JQ/tb1btEUEA== X-Received: by 2002:adf:f1d1:0:b0:2cf:e8b2:4f76 with SMTP id z17-20020adff1d1000000b002cfe8b24f76mr7305646wro.66.1679065464789; Fri, 17 Mar 2023 08:04:24 -0700 (PDT) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:52eb:f6ff:feb3:451a]) by smtp.gmail.com with ESMTPSA id q14-20020a05600000ce00b002be505ab59asm2133773wrx.97.2023.03.17.08.04.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Mar 2023 08:04:24 -0700 (PDT) From: Neil Armstrong Subject: [PATCH v4 00/12] soc: qcom: add UCSI function to PMIC GLINK Date: Fri, 17 Mar 2023 16:04:16 +0100 Message-Id: <20230130-topic-sm8450-upstream-pmic-glink-v4-0-38bf0f5d07bd@linaro.org> MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIAHCBFGQC/5XOS27DMAwE0KsEWocBLckfZNV7FF3oQ9tCbcmQH KNB4LuHyS7oyssZgG/4EIVyoCKup4fItIUSUuSgzyfhRhMHguA5C4lSYaUQ1rQEB2XudI1wW8q aycywzFwOU4i/oKwyaFvrvFKCGWsKgc0mupGheJsmLpdMffh7737/cB5DWVO+v9/Yqld7YHGrA AEtGtcbzzf0xbXJ6ZLyIF76Jo+KksW26snIutGt7v+J6qioWNSua9DLpvay+xD3fX8C4Wn/nIo BAAA= To: Heikki Krogerus , Greg Kroah-Hartman , Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Catalin Marinas , Will Deacon Cc: linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Neil Armstrong , Rob Herring X-Mailer: b4 0.12.1 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The PMIC GLINK interface offers an UCSI endpoint for newer SoCs, the UCSI exchange is necessary to configure the USB-C port USB role and altmode on the SM8450 HDK and SM8550 MTP boards. Since the DT description is the same, support for SM8350 HDK is also added. This patchset focuses on USB and disables altmode support on those 2 SoCs until DP altmode over the combo phy is supported. Depends on PMIC Glink patchset at [1]. [1] https://lore.kernel.org/all/20230130042003.577063-1-quic_bjorande@quicinc.com/ Signed-off-by: Neil Armstrong --- Changes in v4: - Handle remove for UCSI driver - Fixup client mask match data handling - Added USB ports bindings review tag - Link to v3: https://lore.kernel.org/r/20230130-topic-sm8450-upstream-pmic-glink-v3-0-4c860d265d28@linaro.org Changes in v3: - Fixed patch 1 by moving mask to pmic_glink_of_match - Fixed patch 8 by adding back hsphy - Add bindings change to dwc3 to support separate HS & SS OF graph links - Link to v2: https://lore.kernel.org/r/20230130-topic-sm8450-upstream-pmic-glink-v2-0-71fea256474f@linaro.org Changes in v2: - Moved the dwc3 port subnodes to dtsi - Added SM8350 HDK support - Added help about ucsi module name - Added bindings acks - Fixed sm8550 pmic glink compatible - Added more description in config update patch - Link to v1: https://lore.kernel.org/r/20230130-topic-sm8450-upstream-pmic-glink-v1-0-0b0acfad301e@linaro.org --- Neil Armstrong (12): usb: typec: ucsi: add PMIC Glink UCSI driver dt-bindings: soc: qcom: qcom,pmic-glink: document SM8450 compatible dt-bindings: soc: qcom: qcom,pmic-glink: document SM8550 compatible soc: qcom: pmic_glink: register ucsi aux device dt-bindings: usb: snps,dwc3: document HS & SS OF graph ports arm64: dts: qcom: sm8350: add port subnodes in dwc3 node arm64: dts: qcom: sm8450: add port subnodes in dwc3 node arm64: dts: qcom: sm8550: add port subnodes in dwc3 node arm64: dts: qcom: sm8350-hdk: add pmic glink node arm64: dts: qcom: sm8450-hdk: add pmic glink node arm64: dts: qcom: sm8550-mtp: add pmic glink node arm64: defconfig: add PMIC GLINK modules .../bindings/soc/qcom/qcom,pmic-glink.yaml | 2 + .../devicetree/bindings/usb/snps,dwc3.yaml | 16 + arch/arm64/boot/dts/qcom/sm8350-hdk.dts | 67 +++- arch/arm64/boot/dts/qcom/sm8350.dtsi | 19 ++ arch/arm64/boot/dts/qcom/sm8450-hdk.dts | 45 ++- arch/arm64/boot/dts/qcom/sm8450.dtsi | 19 ++ arch/arm64/boot/dts/qcom/sm8550-mtp.dts | 45 ++- arch/arm64/boot/dts/qcom/sm8550.dtsi | 19 ++ arch/arm64/configs/defconfig | 4 + drivers/soc/qcom/pmic_glink.c | 65 +++- drivers/usb/typec/ucsi/Kconfig | 10 + drivers/usb/typec/ucsi/Makefile | 1 + drivers/usb/typec/ucsi/ucsi_glink.c | 345 +++++++++++++++++++++ 13 files changed, 642 insertions(+), 15 deletions(-) --- base-commit: 6f72958a49f68553f2b6ff713e8c8e51a34c1e1e change-id: 20230130-topic-sm8450-upstream-pmic-glink-3b3a0b7bcd33 Best regards,