Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp2619733lqb; Tue, 28 May 2024 05:53:47 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWxdjLmDtfkdJUDfHu5IADB0QG4VJZLGknjhnIDWegDluJB4eM4MtQYZi00uPg2CuNAkCeGjgrxAmgx14vmF1bqBccKYjrJXwERJBtaOQ== X-Google-Smtp-Source: AGHT+IEe6hqRzGvDE7PBxICf3Au5zsjec9QPLB4waohSN+1EquFxSDbs3qRHubt92T3qdgGTUi8+ X-Received: by 2002:a17:906:2a41:b0:a5c:dd3f:9151 with SMTP id a640c23a62f3a-a62643ebadcmr810952666b.35.1716900826918; Tue, 28 May 2024 05:53:46 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716900826; cv=pass; d=google.com; s=arc-20160816; b=vNUyHDf5MA4FLiEORLVQqPyqfKaOiBmeRtY2exTndnRRBXGldiYdca/2fb5DxpfXEe oi1qO4wTLPB52nOU6Bspl0be9jrkQBOrGJUYzO+oO0yeUF+tU9WO+VemNvtqfdF3Y4Mb a1GS3+UI1yPLhJv40MNipHfcFuH65DprlV2yXk2slE8+vaS88/ItUUKk/B3A1LodlcSb RIdTJ+40HJUl5e6CFlxA1dhXREwXPFclLBr2W6m6U3dklbLFRSnb04A9Xk7am/5fAn4F srwR6bZQVh9+kM/EtNfmzWN50Q0Dg4FfsJ9u9vLWS5QLQOg2xIy4AYFegrtM6vjUiwjD QDZA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=IhfLeEz31nnpbep1wtfE79deZVn4RTMnQcliKUfwmsk=; fh=+/A4tC9z2Q+Vq3CAbTJAlyymLQ92bbNiCFpOKfLcaeg=; b=x9yugc7NYKPyGc4V6oJhUn2swDBmNd9sFZPEgqrcS+UPRDQlV3UMvZQydP390sQWGb 8b976OASy1UoxZwovrkt17KQYvuED78LHYZpuuErCed7Rw1lnxnfsy6Cyjn2Cr2XJMBr Oc7Wn/5wHW4c8AUjJ/ouO7wOW2s03kAZS06G9ZTiD7/zsY/yDndDbKk5m4Q0TTieEaAj vntQWlQ2JcSiMSnFswcvybQnU65MFLP7NtHSvnFuWGCOSpDcER4OCWSHYu/atrrufDfQ fJoj/FgIBWbr03VxfXW6/0fnXTBo/e1rRoPpCROGXbXhJPjshcAZSZlcc7jiSn3gcKCf qT6A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wfnDEyPu; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-192335-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-192335-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id a640c23a62f3a-a626cdd20c2si512444166b.993.2024.05.28.05.53.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 May 2024 05:53:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-192335-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wfnDEyPu; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-192335-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-192335-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 7E1EE1F22C94 for ; Tue, 28 May 2024 12:53:46 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9FBF016E86B; Tue, 28 May 2024 12:53:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="wfnDEyPu" Received: from mail-lf1-f49.google.com (mail-lf1-f49.google.com [209.85.167.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8520716D9AE for ; Tue, 28 May 2024 12:53:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.49 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716900798; cv=none; b=jfTKSv7UjVtLclcGEnAawStEw/d8xkgBffezu8YDmsy5tPx8Bs63PnglZK3NUazgfybHzI/X/lF7dRZi89WG63LyqiV8qcqPZYd+B4e8+ODFPL3Rv+h18C6DvSdUgjrsdWPzZqQBnUwoJq21GYuCYUtWCUsQdftxxmti71qjOIc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716900798; c=relaxed/simple; bh=nmYSDivuU1fGiaHNtpmlfGXSTR8QMXOhtvK7Fro/hPU=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=gMEjSag+8bNxg/Cy6YrV7LvZN6Q/sEbf/0/r/XnGD4UEFRNKGW7CzC0tTegpw9KPDs0JgzeH1jhENj2mX5ZuA17CytYVNvCvcSiJcwh032cNaA7G/D8gtHeuvG1im6/YKyNDu7w7UKoW0FfRC/5oVufqk2HZ9G8w6R/ki7dCK8M= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=wfnDEyPu; arc=none smtp.client-ip=209.85.167.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-lf1-f49.google.com with SMTP id 2adb3069b0e04-5238b5c080cso920864e87.1 for ; Tue, 28 May 2024 05:53:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1716900794; x=1717505594; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=IhfLeEz31nnpbep1wtfE79deZVn4RTMnQcliKUfwmsk=; b=wfnDEyPuX2cffwaxTSNsjQBE5A09Ff0g1vx+EfuWWMJzCNm86zQ5MjkZdrtVi9YisN Y78RWXKmjraKp/baA5UCC/T2V4+hOGthPHeAwt/8Zk+EeV84LBR5TtNgeX9478VXtkmp kJr15kbQZxVcD+JCE7GnyIJ0vLiI8IaNvkL8HXNTvLBBtlOeD8V8mu1Z3ZssBYcIwmyD 5tPQgASLDtG0y1BAA1oFA7H7+IotPsAG8/3sWCIqu03PJXwATSKkETCV36Ptl/9WYRF5 o8408ChVQiPpylARuPy+hg7smzJem7Nv7D+f/8nxOB7H5Ho4Fu8P0vOQDBiRkZ9lE+3t x47w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716900794; x=1717505594; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=IhfLeEz31nnpbep1wtfE79deZVn4RTMnQcliKUfwmsk=; b=NZC/cxbliQx/wsiSGxJa1J3Zwr+38vbdD+r5Z5odwiCgMvixta92Z8Q7z9Yz5Nc8sr vIqoJVkzVIxkhWSJx+VcDAS2Kf5hl+eDjSW7rea4i9qfZB4J5ca0gvU+229OOnhRU/Lf Tb3p3pC3koQhgcCXrhDkSv7jAg5yRolJIDygGOUbBEroqh/jhmFMSOou50mXSBFFCEmQ 01V2/xD0a7Di8sV6HP5FktsAbmJcfRJpcCSzkRcwFl8chIuSmOauVEVmvuEbvx8XA1M5 FkjhcoJmTwXN2NzB9UF2y38g49tzYWaV0Dd+qW9XXo3xLOpZIB7xHnHcOewJUqivTD8n LsiA== X-Forwarded-Encrypted: i=1; AJvYcCWBNQc4IDu/gFAywjiA6zk3Wu/foILklhQmx8TTeUSuEJHpdaFTaQ7j52x0J5YMb2/pqzDOdtSVdYsukPR31wmsO7+otX0SlawCFKvo X-Gm-Message-State: AOJu0YyaInofC3a2xWPpwYuw1kfs3o6aoSNIEaPj+aR1+2aPFRp97FjK MWPq7x5O2DImY+nXOmmCCj9DP2IuxZKdSL5AD3Oh3n0r6D8tyiPYuE+pwFLzYwA= X-Received: by 2002:a19:380a:0:b0:516:d18b:eae8 with SMTP id 2adb3069b0e04-52964caa6damr6901115e87.41.1716900793703; Tue, 28 May 2024 05:53:13 -0700 (PDT) Received: from ?IPV6:2a00:f41:c97:23a9:35bc:df2e:d894:2c76? ([2a00:f41:c97:23a9:35bc:df2e:d894:2c76]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-529712f1c0fsm949009e87.279.2024.05.28.05.53.11 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 28 May 2024 05:53:13 -0700 (PDT) Message-ID: Date: Tue, 28 May 2024 14:53:09 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 08/10] arm64: dts: qcom: sc8180x: Add USB MP controller and phys To: Bjorn Andersson , Vinod Koul , Kishon Vijay Abraham I , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Michael Turquette , Stephen Boyd , Greg Kroah-Hartman , Wesley Cheng Cc: linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-usb@vger.kernel.org, Bjorn Andersson References: <20240525-sc8180x-usb-mp-v1-0-60a904392438@quicinc.com> <20240525-sc8180x-usb-mp-v1-8-60a904392438@quicinc.com> Content-Language: en-US From: Konrad Dybcio In-Reply-To: <20240525-sc8180x-usb-mp-v1-8-60a904392438@quicinc.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 5/25/24 20:04, Bjorn Andersson wrote: > From: Bjorn Andersson > > The SC8180X platform comes with a multiport DWC3 controller with two > ports, each connected to a pair of HighSpeed and QMP SuperSpeed PHYs. > > Describe these blocks. > > Signed-off-by: Bjorn Andersson > --- > arch/arm64/boot/dts/qcom/sc8180x.dtsi | 146 ++++++++++++++++++++++++++++++++++ > 1 file changed, 146 insertions(+) > > diff --git a/arch/arm64/boot/dts/qcom/sc8180x.dtsi b/arch/arm64/boot/dts/qcom/sc8180x.dtsi > index 9ef3fa40e1d8..0950dc7adb20 100644 > --- a/arch/arm64/boot/dts/qcom/sc8180x.dtsi > +++ b/arch/arm64/boot/dts/qcom/sc8180x.dtsi > @@ -2511,6 +2511,34 @@ usb_sec_hsphy: phy@88e3000 { > status = "disabled"; > }; > > + usb_mp0_hsphy: phy@88e4000 { Even though the register names are MPn, I think this is a bit confusing.. There's only one MP controller, so perhaps usb_mp_hsphy0? [...] > + clocks = <&gcc GCC_USB3_MP_PHY_AUX_CLK>, > + <&gcc GCC_USB3_PRIM_CLKREF_CLK>, > + <&gcc GCC_USB3_MP_PHY_COM_AUX_CLK>, > + <&gcc GCC_USB3_MP_PHY_PIPE_0_CLK>; PIPE_1_CLK > + clock-names = "aux", "ref", "com_aux", "pipe"; This could be a vertical list > + > + resets = <&gcc GCC_USB3_UNIPHY_MP1_BCR>, > + <&gcc GCC_USB3UNIPHY_PHY_MP1_BCR>; > + reset-names = "phy", "phy_phy"; > + > + power-domains = <&gcc USB30_MP_GDSC>; > + > + #clock-cells = <0>; > + clock-output-names = "usb2_phy1_pipe_clk"; > + > + #phy-cells = <0>; > + > + status = "disabled"; > + }; > + > usb_sec_qmpphy: phy@88ee000 { > compatible = "qcom,sc8180x-qmp-usb3-dp-phy"; > reg = <0 0x088ee000 0 0x18c>, > @@ -2662,6 +2738,76 @@ gem_noc: interconnect@9680000 { > qcom,bcm-voters = <&apps_bcm_voter>; > }; > > + usb_mp: usb@a4f8800 { > + compatible = "qcom,sc8180x-dwc3-mp", "qcom,dwc3"; > + reg = <0 0x0a4f8800 0 0x400>; > + #address-cells = <2>; > + #size-cells = <2>; > + ranges; > + dma-ranges; > + > + clocks = <&gcc GCC_CFG_NOC_USB3_MP_AXI_CLK>, > + <&gcc GCC_USB30_MP_MASTER_CLK>, > + <&gcc GCC_AGGRE_USB3_MP_AXI_CLK>, > + <&gcc GCC_USB30_MP_SLEEP_CLK>, > + <&gcc GCC_USB30_MP_MOCK_UTMI_CLK>, > + <&gcc GCC_USB3_SEC_CLKREF_CLK>; This is used by the secondary DWC3 (non-MP). Are you sure? Actually, are we sure that these clocks are really supplying the DWC3s? > + clock-names = "cfg_noc", > + "core", > + "iface", > + "sleep", > + "mock_utmi", > + "xo"; > + > + interconnects = <&aggre1_noc MASTER_USB3_2 0 &mc_virt SLAVE_EBI_CH0 0>, > + <&gem_noc MASTER_AMPSS_M0 0 &config_noc SLAVE_USB3_2 0>; > + interconnect-names = "usb-ddr", "apps-usb"; > + > + assigned-clocks = <&gcc GCC_USB30_MP_MOCK_UTMI_CLK>, > + <&gcc GCC_USB30_MP_MASTER_CLK>; > + assigned-clock-rates = <19200000>, <200000000>; > + > + interrupts-extended = <&intc GIC_SPI 656 IRQ_TYPE_LEVEL_HIGH>, > + <&intc GIC_SPI 655 IRQ_TYPE_LEVEL_HIGH>, > + <&intc GIC_SPI 658 IRQ_TYPE_LEVEL_HIGH>, > + <&intc GIC_SPI 657 IRQ_TYPE_LEVEL_HIGH>, > + <&pdc 59 IRQ_TYPE_EDGE_BOTH>, > + <&pdc 46 IRQ_TYPE_EDGE_BOTH>, > + <&pdc 71 IRQ_TYPE_EDGE_BOTH>, > + <&pdc 68 IRQ_TYPE_EDGE_BOTH>, > + <&pdc 7 IRQ_TYPE_LEVEL_HIGH>, > + <&pdc 30 IRQ_TYPE_LEVEL_HIGH>; > + interrupt-names = "pwr_event_1", "pwr_event_2", > + "hs_phy_1", "hs_phy_2", > + "dp_hs_phy_1", "dm_hs_phy_1", > + "dp_hs_phy_2", "dm_hs_phy_2", > + "ss_phy_1", "ss_phy_2"; > + > + power-domains = <&gcc USB30_MP_GDSC>; > + > + resets = <&gcc GCC_USB30_MP_BCR>; > + > + status = "disabled"; > + > + usb_mp_dwc3: usb@a400000 { > + compatible = "snps,dwc3"; > + reg = <0 0x0a400000 0 0xcd00>; > + interrupts = ; > + iommus = <&apps_smmu 0x60 0>; > + snps,dis_u2_susphy_quirk; > + snps,dis_enblslpm_quirk; sa8195-usb.dtsi lists a bunch more fluff: snps,has-lpm-erratum; snps,hird-threshold = /bits/ 8 <0x0>; snps,is-utmi-l1-suspend; snps,ssp-u3-u0-quirk; snps,dis-u1-entry-quirk; snps,dis-u2-entry-quirk; snps,dis_u3_susphy_quirk; snps,force-gen1; maximum-speed = "super-speed"; the irq numbers look good Konrad