From patchwork Tue Jan 14 05:11:34 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938404 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C6B4A233556 for ; Tue, 14 Jan 2025 05:05:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831151; cv=none; b=XfShty+/UoUpOOzPMGG8wrAibYyyHr4yM5UTdqyK8TZYz6IIL4dqnIng0+DtN7YrzRlOmFrQP6MiXj5nlhrNIiX3sn5/W4d6nBdGLaR/pbxFK6500HjZvUhP2TvKLbRqtn9y15FIvYUWrpQ1BpbqrXQDg2x6NV6ry/Tt8khhb5U= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831151; c=relaxed/simple; bh=G6dtBU2rfEreIT2rFdyqftSefNbsw6nq18RbsWsp5iY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ZXrBUd4xxlwu8cknT6cmYU2S9xFe8DA7rHY2ogcBoWXwWJpxjAuTKE1jmxR7XulcfhIzbq/vwaUau5Gk/NJPpRqJJj7CvmvEEyKKQaGyWySOpuHPEr7cnaCxCrd7Z+1rWkyJ5wzdAt77fWKvMyX4MOg0NS0EbDHhtT3PrpOUzi4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=U3CARc/g; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="U3CARc/g" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DKrkBY023146 for ; Tue, 14 Jan 2025 05:05:48 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= Gf68pBND6Bw8Zne3bWp+1+Yl8GBhak+geAciswXOc+E=; b=U3CARc/g+oBFma+x uYjF5bK9Fm6UOHVlBfrJz1Gk/f8VDjPzFI7vHzrhQ2262i5yNkESzQJeFA/JM26W ptyXRg0ABKVlA3bjxj155HdYp2tp0Qq99FP6ekfYQ1W0vEqrjZV1Y/23Qp0k7UqE 3pWqgXOWpMdg+CnJRkK0NlE8z/oRSovaHKTM0V23Zz+q7wf7zj3jtkyPnFy7cHeH oYywycLRXF6JtDPyqLtUTZl1VrH0I6BonUYtOHCSM+odgLhzMXo20QhWMimsZBrf HHlRJSllYJ3aEw+J66jHt5WWIo3eiTLKEh9+TfL0qk71uWFE+M5mxAqxnRewzYmQ ILNhgQ== Received: from mail-oo1-f70.google.com (mail-oo1-f70.google.com [209.85.161.70]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445a928v6c-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:47 +0000 (GMT) Received: by mail-oo1-f70.google.com with SMTP id 006d021491bc7-5f696a2ee38so4153293eaf.1 for ; Mon, 13 Jan 2025 21:05:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831146; x=1737435946; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Gf68pBND6Bw8Zne3bWp+1+Yl8GBhak+geAciswXOc+E=; b=OaXvqJxLtDpmdTrClT8CpXUc5IEoYKSt3Tm4H4BO7/81LbQntWcDJhig5n2T/0b9UV i1nlSKkQruaeBNP/8A7g23pRcDazDa2WSlMG+QidiYm1GEYGSxEspC8xtylz51a9LzZ6 zmKUYr5kCPy7JHpMZKSSbHti5M7LKE+DnCG8zxrbqYyzs7aBRQl0z1GZ5UVdjqbdC3jr iTyLd1mE02N8ZXvgp6OPcTSjONmfqtrK3R9bi5Zs6U19YYMvaFKYB65eJP6ebHu4mkOz CXp9ZIK2DedyWEaUFKYTzeaMuWFF2tkZtDsozv6+TuUbtaiV6E2rlvtmSjHUnNewRZtF tm+w== X-Gm-Message-State: AOJu0Yw4ZgWpUQ7SZyNQNHUlFVJaiuK8iS8A93MNlM7YaFOIjueMIZsk kgS+y3wWxs1CVGvPi9Y597zqQeNtoBg1iB0NU0cFOua50InVrn1uxJx1jJUYNn2h9IQSEg+NZmI Iery/Tglye5aDmYZPU2gIa+ypAVKqNekbN9yaCCCmz19PHmXr+L3cM/OY/WnWzc7B X-Gm-Gg: ASbGncv7z/WJoTBk1uJGhQZCE9Mwlxx/uU8McPAkIEQq1fNLxjmQB3eTmoXUWSpj3DH 2iSdJe72PFQvAUS6mtPmTd4LiOtQqnUsX04V4rMgbvL9Q2kMD56QKdikMIyDp7O/zlIs/Cr1JV6 xNKcELayA/0IGd/ugCIcFdYc6SB583bFcxa5UOSEoWWzLPzm30sbXwzYmznbHPx3mMiAIxoHKIt jzTJsr8NBxbDQ7lYRSa2/M+PXabU+V3k7NjR5JJF2mnCiGZy2AIbWNqd14O3iZLw9mxU6ms+7fr D+mu/FNhgM3lPEIQ41gez+TwQBjM2Th/UI5/06X9sXUpYM9uPdGI4pEC X-Received: by 2002:a05:6820:1520:b0:5f6:d896:4afe with SMTP id 006d021491bc7-5f7309645d5mr13975600eaf.3.1736831145833; Mon, 13 Jan 2025 21:05:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IF1lU6i27DwfQZgvaaz4U1vt5GzXa+IZsX7I/BiaDc+J/WVyAMzVDxPSrBxx/AL3//iDwyMpQ== X-Received: by 2002:a05:6820:1520:b0:5f6:d896:4afe with SMTP id 006d021491bc7-5f7309645d5mr13975566eaf.3.1736831144933; Mon, 13 Jan 2025 21:05:44 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:44 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:34 -0800 Subject: [PATCH v3 01/12] dt-bindings: usb: snps,dwc3: Split core description Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-1-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=29276; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=G6dtBU2rfEreIT2rFdyqftSefNbsw6nq18RbsWsp5iY=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIUyYuIIj988QjM2A610Bd/+42u2axIpEAqS EvVeaBYwViJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFBUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcWGWA//Yr1XCAl7N8ZgvipJism9Pj9GjU6GnpFUjbH4udY bpxRnkjdoig1TgFyJ1AX1K1PsYTtKprdAU5lR7RUgf2XQia347+SPYfuH2v1r4dn5UIyfkwlFVo jU/9z+i9OIgi8JkVxaSC8sWQ5+T3F9Wbr5KkCTAVEg8yFCWbGZiXURDHavN2sWcQqCd1GBjuR2z uTG8OcO7M3q9heU7ooyi/u82cLDf+MI7H77c/jeQGqEZVrc39NTPYNU97teJX4e8D25FgQ71BT2 OG1D6KW7e8xW/KKQaqGXYOKveK2CBNcj1nPwOmoVcCGsNG367w1c367LKs22+H41Y05gaZHgCf9 RTmY+5+b18Ujyc5oWbbk3h7iACUnHzlSRvmrpAtJdfTolor36lvnxFozzHmi6lbIZG1c+TB4Hex sBv2Wvq0zlf1FA3cV5WCTWWt8BgzlToPK5pbWCJNw/87yFXRpIT/Tk+ZDXNXCmYPq45o25dwAPz NfcrUZezOfEq2bg3Rp0+00DntIjVyOhfsOIxqT5bOhepoM14E2cE873NwNgrqdQozrkvFf0SrvP QMfIqCKIJLbLArrxoOIl6T5nK1qT8XN9dCVynu+dNPvriY2imhpbWPctMhWJu7y4RionAp68llp xfSZ220GnGAaus4pw5OuXDdEdZlqTRXNzExtRCms3nSg= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: yGMnZtcO-S-KOuWmLHAOdYQCUfEXa2LD X-Proofpoint-ORIG-GUID: yGMnZtcO-S-KOuWmLHAOdYQCUfEXa2LD X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 malwarescore=0 suspectscore=0 impostorscore=0 adultscore=0 priorityscore=1501 spamscore=0 lowpriorityscore=0 clxscore=1015 mlxlogscore=999 phishscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 The Synopsys DWC3 core is found either as a standalone block or integrated with vendor glue logic. So far the latter has been described as two separate IP blocks in DeviceTree, but the two parts are not separate. In the case where the core is integrated together with vendor glue, resources such as clock and resets are often customized by the vendor, such that the standard properties doesn't make sense. Split the snps,dwc3 binding in a description of the core properties and the standard "glue" properties, in order to allow vendor bindings to inherit the core properties. Reviewed-by: Rob Herring (Arm) Signed-off-by: Bjorn Andersson --- .../devicetree/bindings/usb/snps,dwc3-common.yaml | 415 +++++++++++++++++++++ .../devicetree/bindings/usb/snps,dwc3.yaml | 391 +------------------ 2 files changed, 416 insertions(+), 390 deletions(-) diff --git a/Documentation/devicetree/bindings/usb/snps,dwc3-common.yaml b/Documentation/devicetree/bindings/usb/snps,dwc3-common.yaml new file mode 100644 index 000000000000..c956053fd036 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/snps,dwc3-common.yaml @@ -0,0 +1,415 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/snps,dwc3-common.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Synopsys DesignWare USB3 Controller common properties + +maintainers: + - Felipe Balbi + +description: + Defines the properties of the DWC3 core as being embedded in either an + vendor-specific implementation or as a standalone component. + +allOf: + - $ref: usb-drd.yaml# + - if: + properties: + dr_mode: + const: peripheral + + required: + - dr_mode + then: + $ref: usb.yaml# + else: + $ref: usb-xhci.yaml# + +properties: + extcon: + maxItems: 1 + deprecated: true + + usb-phy: + minItems: 1 + items: + - description: USB2/HS PHY + - description: USB3/SS PHY + + phys: + minItems: 1 + maxItems: 19 + + phy-names: + minItems: 1 + maxItems: 19 + oneOf: + - items: + enum: [ usb2-phy, usb3-phy ] + - items: + pattern: "^usb(2-([0-9]|1[0-4])|3-[0-3])$" + + snps,usb2-lpm-disable: + description: Indicate if we don't want to enable USB2 HW LPM for host + mode. + type: boolean + + snps,usb3_lpm_capable: + description: Determines if platform is USB3 LPM capable + type: boolean + + snps,usb2-gadget-lpm-disable: + description: Indicate if we don't want to enable USB2 HW LPM for gadget + mode. + type: boolean + + snps,dis-start-transfer-quirk: + description: + When set, disable isoc START TRANSFER command failure SW work-around + for DWC_usb31 version 1.70a-ea06 and prior. + type: boolean + + snps,disable_scramble_quirk: + description: + True when SW should disable data scrambling. Only really useful for FPGA + builds. + type: boolean + + snps,has-lpm-erratum: + description: True when DWC3 was configured with LPM Erratum enabled + type: boolean + + snps,lpm-nyet-threshold: + description: LPM NYET threshold + $ref: /schemas/types.yaml#/definitions/uint8 + + snps,u2exit_lfps_quirk: + description: Set if we want to enable u2exit lfps quirk + type: boolean + + snps,u2ss_inp3_quirk: + description: Set if we enable P3 OK for U2/SS Inactive quirk + type: boolean + + snps,req_p1p2p3_quirk: + description: + When set, the core will always request for P1/P2/P3 transition sequence. + type: boolean + + snps,del_p1p2p3_quirk: + description: + When set core will delay P1/P2/P3 until a certain amount of 8B10B errors + occur. + type: boolean + + snps,del_phy_power_chg_quirk: + description: When set core will delay PHY power change from P0 to P1/P2/P3. + type: boolean + + snps,lfps_filter_quirk: + description: When set core will filter LFPS reception. + type: boolean + + snps,rx_detect_poll_quirk: + description: + when set core will disable a 400us delay to start Polling LFPS after + RX.Detect. + type: boolean + + snps,tx_de_emphasis_quirk: + description: When set core will set Tx de-emphasis value + type: boolean + + snps,tx_de_emphasis: + description: + The value driven to the PHY is controlled by the LTSSM during USB3 + Compliance mode. + $ref: /schemas/types.yaml#/definitions/uint8 + enum: + - 0 # -6dB de-emphasis + - 1 # -3.5dB de-emphasis + - 2 # No de-emphasis + + snps,dis_u3_susphy_quirk: + description: When set core will disable USB3 suspend phy + type: boolean + + snps,dis_u2_susphy_quirk: + description: When set core will disable USB2 suspend phy + type: boolean + + snps,dis_enblslpm_quirk: + description: + When set clears the enblslpm in GUSB2PHYCFG, disabling the suspend signal + to the PHY. + type: boolean + + snps,dis-u1-entry-quirk: + description: Set if link entering into U1 needs to be disabled + type: boolean + + snps,dis-u2-entry-quirk: + description: Set if link entering into U2 needs to be disabled + type: boolean + + snps,dis_rxdet_inp3_quirk: + description: + When set core will disable receiver detection in PHY P3 power state. + type: boolean + + snps,dis-u2-freeclk-exists-quirk: + description: + When set, clear the u2_freeclk_exists in GUSB2PHYCFG, specify that USB2 + PHY doesn't provide a free-running PHY clock. + type: boolean + + snps,dis-del-phy-power-chg-quirk: + description: + When set core will change PHY power from P0 to P1/P2/P3 without delay. + type: boolean + + snps,dis-tx-ipgap-linecheck-quirk: + description: When set, disable u2mac linestate check during HS transmit + type: boolean + + snps,parkmode-disable-ss-quirk: + description: + When set, all SuperSpeed bus instances in park mode are disabled. + type: boolean + + snps,parkmode-disable-hs-quirk: + description: + When set, all HighSpeed bus instances in park mode are disabled. + type: boolean + + snps,dis_metastability_quirk: + description: + When set, disable metastability workaround. CAUTION! Use only if you are + absolutely sure of it. + type: boolean + + snps,dis-split-quirk: + description: + When set, change the way URBs are handled by the driver. Needed to + avoid -EPROTO errors with usbhid on some devices (Hikey 970). + type: boolean + + snps,gfladj-refclk-lpm-sel-quirk: + description: + When set, run the SOF/ITP counter based on ref_clk. + type: boolean + + snps,resume-hs-terminations: + description: + Fix the issue of HS terminations CRC error on resume by enabling this + quirk. When set, all the termsel, xcvrsel, opmode becomes 0 during end + of resume. This option is to support certain legacy ULPI PHYs. + type: boolean + + snps,ulpi-ext-vbus-drv: + description: + Some ULPI USB PHY does not support internal VBUS supply, and driving + the CPEN pin, requires the configuration of the ulpi DRVVBUSEXTERNAL + bit. When set, the xhci host will configure the USB2 PHY drives VBUS + with an external supply. + type: boolean + + snps,is-utmi-l1-suspend: + description: + True when DWC3 asserts output signal utmi_l1_suspend_n, false when + asserts utmi_sleep_n. + type: boolean + + snps,hird-threshold: + description: HIRD threshold + $ref: /schemas/types.yaml#/definitions/uint8 + + snps,hsphy_interface: + description: + High-Speed PHY interface selection between UTMI+ and ULPI when the + DWC_USB3_HSPHY_INTERFACE has value 3. + $ref: /schemas/types.yaml#/definitions/string + enum: [utmi, ulpi] + + snps,quirk-frame-length-adjustment: + description: + Value for GFLADJ_30MHZ field of GFLADJ register for post-silicon frame + length adjustment when the fladj_30mhz_sdbnd signal is invalid or + incorrect. + $ref: /schemas/types.yaml#/definitions/uint32 + minimum: 0 + maximum: 0x3f + + snps,ref-clock-period-ns: + description: + Value for REFCLKPER field of GUCTL register for reference clock period in + nanoseconds, when the hardware set default does not match the actual + clock. + + This binding is deprecated. Instead, provide an appropriate reference clock. + minimum: 8 + maximum: 62 + deprecated: true + + snps,rx-thr-num-pkt: + description: + USB RX packet threshold count. In host mode, this field specifies + the space that must be available in the RX FIFO before the core can + start the corresponding USB RX transaction (burst). + In device mode, this field specifies the space that must be + available in the RX FIFO before the core can send ERDY for a + flow-controlled endpoint. It is only used for SuperSpeed. + The valid values for this field are from 1 to 15. (DWC3 SuperSpeed + USB 3.0 Controller Databook) + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 15 + + snps,rx-max-burst: + description: + Max USB RX burst size. In host mode, this field specifies the + Maximum Bulk IN burst the DWC_usb3 core can perform. When the system + bus is slower than the USB, RX FIFO can overrun during a long burst. + You can program a smaller value to this field to limit the RX burst + size that the core can perform. It only applies to SS Bulk, + Isochronous, and Interrupt IN endpoints in the host mode. + In device mode, this field specifies the NUMP value that is sent in + ERDY for an OUT endpoint. + The valid values for this field are from 1 to 16. (DWC3 SuperSpeed + USB 3.0 Controller Databook) + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + snps,tx-thr-num-pkt: + description: + USB TX packet threshold count. This field specifies the number of + packets that must be in the TXFIFO before the core can start + transmission for the corresponding USB transaction (burst). + This count is valid in both host and device modes. It is only used + for SuperSpeed operation. + Valid values are from 1 to 15. (DWC3 SuperSpeed USB 3.0 Controller + Databook) + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 15 + + snps,tx-max-burst: + description: + Max USB TX burst size. When the system bus is slower than the USB, + TX FIFO can underrun during a long burst. Program a smaller value + to this field to limit the TX burst size that the core can execute. + In Host mode, it only applies to SS Bulk, Isochronous, and Interrupt + OUT endpoints. This value is not used in device mode. + Valid values are from 1 to 16. (DWC3 SuperSpeed USB 3.0 Controller + Databook) + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + snps,rx-thr-num-pkt-prd: + description: + Periodic ESS RX packet threshold count (host mode only). Set this and + snps,rx-max-burst-prd to a valid, non-zero value 1-16 (DWC_usb31 + programming guide section 1.2.4) to enable periodic ESS RX threshold. + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + snps,rx-max-burst-prd: + description: + Max periodic ESS RX burst size (host mode only). Set this and + snps,rx-thr-num-pkt-prd to a valid, non-zero value 1-16 (DWC_usb31 + programming guide section 1.2.4) to enable periodic ESS RX threshold. + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + snps,tx-thr-num-pkt-prd: + description: + Periodic ESS TX packet threshold count (host mode only). Set this and + snps,tx-max-burst-prd to a valid, non-zero value 1-16 (DWC_usb31 + programming guide section 1.2.3) to enable periodic ESS TX threshold. + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + snps,tx-max-burst-prd: + description: + Max periodic ESS TX burst size (host mode only). Set this and + snps,tx-thr-num-pkt-prd to a valid, non-zero value 1-16 (DWC_usb31 + programming guide section 1.2.3) to enable periodic ESS TX threshold. + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 1 + maximum: 16 + + tx-fifo-resize: + description: Determines if the TX fifos can be dynamically resized depending + on the number of IN endpoints used and if bursting is supported. This + may help improve bandwidth on platforms with higher system latencies, as + increased fifo space allows for the controller to prefetch data into its + internal memory. + type: boolean + + tx-fifo-max-num: + description: Specifies the max number of packets the txfifo resizing logic + can account for when higher endpoint bursting is used. (bMaxBurst > 6) The + higher the number, the more fifo space the txfifo resizing logic will + allocate for that endpoint. + $ref: /schemas/types.yaml#/definitions/uint8 + minimum: 3 + + snps,incr-burst-type-adjustment: + description: + Value for INCR burst type of GSBUSCFG0 register, undefined length INCR + burst type enable and INCRx type. A single value means INCRX burst mode + enabled. If more than one value specified, undefined length INCR burst + type will be enabled with burst lengths utilized up to the maximum + of the values passed in this property. + $ref: /schemas/types.yaml#/definitions/uint32-array + minItems: 1 + maxItems: 8 + uniqueItems: true + items: + enum: [1, 4, 8, 16, 32, 64, 128, 256] + + num-hc-interrupters: + maximum: 8 + default: 1 + + port: + $ref: /schemas/graph.yaml#/properties/port + description: + This port is used with the 'usb-role-switch' property to connect the + dwc3 to type C connector. + + ports: + $ref: /schemas/graph.yaml#/properties/ports + description: + Those ports should be used with any connector to the data bus of this + controller using the OF graph bindings specified if the "usb-role-switch" + property is used. + + properties: + port@0: + $ref: /schemas/graph.yaml#/properties/port + description: High Speed (HS) data bus. + + port@1: + $ref: /schemas/graph.yaml#/properties/port + description: Super Speed (SS) data bus. + + wakeup-source: + $ref: /schemas/types.yaml#/definitions/flag + description: + Enable USB remote wakeup. + +required: + - compatible + - reg + +additionalProperties: true +... + diff --git a/Documentation/devicetree/bindings/usb/snps,dwc3.yaml b/Documentation/devicetree/bindings/usb/snps,dwc3.yaml index 1cd0ca90127d..4380bb6fa2f0 100644 --- a/Documentation/devicetree/bindings/usb/snps,dwc3.yaml +++ b/Documentation/devicetree/bindings/usb/snps,dwc3.yaml @@ -15,18 +15,7 @@ description: compatible string. allOf: - - $ref: usb-drd.yaml# - - if: - properties: - dr_mode: - const: peripheral - - required: - - dr_mode - then: - $ref: usb.yaml# - else: - $ref: usb-xhci.yaml# + - $ref: snps,dwc3-common.yaml# properties: compatible: @@ -70,32 +59,9 @@ properties: dma-coherent: true - extcon: - maxItems: 1 - deprecated: true - iommus: maxItems: 1 - usb-phy: - minItems: 1 - items: - - description: USB2/HS PHY - - description: USB3/SS PHY - - phys: - minItems: 1 - maxItems: 19 - - phy-names: - minItems: 1 - maxItems: 19 - oneOf: - - items: - enum: [ usb2-phy, usb3-phy ] - - items: - pattern: "^usb(2-([0-9]|1[0-4])|3-[0-3])$" - power-domains: description: The DWC3 has 2 power-domains. The power management unit (PMU) and @@ -109,361 +75,6 @@ properties: resets: minItems: 1 - snps,usb2-lpm-disable: - description: Indicate if we don't want to enable USB2 HW LPM for host - mode. - type: boolean - - snps,usb3_lpm_capable: - description: Determines if platform is USB3 LPM capable - type: boolean - - snps,usb2-gadget-lpm-disable: - description: Indicate if we don't want to enable USB2 HW LPM for gadget - mode. - type: boolean - - snps,dis-start-transfer-quirk: - description: - When set, disable isoc START TRANSFER command failure SW work-around - for DWC_usb31 version 1.70a-ea06 and prior. - type: boolean - - snps,disable_scramble_quirk: - description: - True when SW should disable data scrambling. Only really useful for FPGA - builds. - type: boolean - - snps,has-lpm-erratum: - description: True when DWC3 was configured with LPM Erratum enabled - type: boolean - - snps,lpm-nyet-threshold: - description: LPM NYET threshold - $ref: /schemas/types.yaml#/definitions/uint8 - - snps,u2exit_lfps_quirk: - description: Set if we want to enable u2exit lfps quirk - type: boolean - - snps,u2ss_inp3_quirk: - description: Set if we enable P3 OK for U2/SS Inactive quirk - type: boolean - - snps,req_p1p2p3_quirk: - description: - When set, the core will always request for P1/P2/P3 transition sequence. - type: boolean - - snps,del_p1p2p3_quirk: - description: - When set core will delay P1/P2/P3 until a certain amount of 8B10B errors - occur. - type: boolean - - snps,del_phy_power_chg_quirk: - description: When set core will delay PHY power change from P0 to P1/P2/P3. - type: boolean - - snps,lfps_filter_quirk: - description: When set core will filter LFPS reception. - type: boolean - - snps,rx_detect_poll_quirk: - description: - when set core will disable a 400us delay to start Polling LFPS after - RX.Detect. - type: boolean - - snps,tx_de_emphasis_quirk: - description: When set core will set Tx de-emphasis value - type: boolean - - snps,tx_de_emphasis: - description: - The value driven to the PHY is controlled by the LTSSM during USB3 - Compliance mode. - $ref: /schemas/types.yaml#/definitions/uint8 - enum: - - 0 # -6dB de-emphasis - - 1 # -3.5dB de-emphasis - - 2 # No de-emphasis - - snps,dis_u3_susphy_quirk: - description: When set core will disable USB3 suspend phy - type: boolean - - snps,dis_u2_susphy_quirk: - description: When set core will disable USB2 suspend phy - type: boolean - - snps,dis_enblslpm_quirk: - description: - When set clears the enblslpm in GUSB2PHYCFG, disabling the suspend signal - to the PHY. - type: boolean - - snps,dis-u1-entry-quirk: - description: Set if link entering into U1 needs to be disabled - type: boolean - - snps,dis-u2-entry-quirk: - description: Set if link entering into U2 needs to be disabled - type: boolean - - snps,dis_rxdet_inp3_quirk: - description: - When set core will disable receiver detection in PHY P3 power state. - type: boolean - - snps,dis-u2-freeclk-exists-quirk: - description: - When set, clear the u2_freeclk_exists in GUSB2PHYCFG, specify that USB2 - PHY doesn't provide a free-running PHY clock. - type: boolean - - snps,dis-del-phy-power-chg-quirk: - description: - When set core will change PHY power from P0 to P1/P2/P3 without delay. - type: boolean - - snps,dis-tx-ipgap-linecheck-quirk: - description: When set, disable u2mac linestate check during HS transmit - type: boolean - - snps,parkmode-disable-ss-quirk: - description: - When set, all SuperSpeed bus instances in park mode are disabled. - type: boolean - - snps,parkmode-disable-hs-quirk: - description: - When set, all HighSpeed bus instances in park mode are disabled. - type: boolean - - snps,dis_metastability_quirk: - description: - When set, disable metastability workaround. CAUTION! Use only if you are - absolutely sure of it. - type: boolean - - snps,dis-split-quirk: - description: - When set, change the way URBs are handled by the driver. Needed to - avoid -EPROTO errors with usbhid on some devices (Hikey 970). - type: boolean - - snps,gfladj-refclk-lpm-sel-quirk: - description: - When set, run the SOF/ITP counter based on ref_clk. - type: boolean - - snps,resume-hs-terminations: - description: - Fix the issue of HS terminations CRC error on resume by enabling this - quirk. When set, all the termsel, xcvrsel, opmode becomes 0 during end - of resume. This option is to support certain legacy ULPI PHYs. - type: boolean - - snps,ulpi-ext-vbus-drv: - description: - Some ULPI USB PHY does not support internal VBUS supply, and driving - the CPEN pin, requires the configuration of the ulpi DRVVBUSEXTERNAL - bit. When set, the xhci host will configure the USB2 PHY drives VBUS - with an external supply. - type: boolean - - snps,is-utmi-l1-suspend: - description: - True when DWC3 asserts output signal utmi_l1_suspend_n, false when - asserts utmi_sleep_n. - type: boolean - - snps,hird-threshold: - description: HIRD threshold - $ref: /schemas/types.yaml#/definitions/uint8 - - snps,hsphy_interface: - description: - High-Speed PHY interface selection between UTMI+ and ULPI when the - DWC_USB3_HSPHY_INTERFACE has value 3. - $ref: /schemas/types.yaml#/definitions/string - enum: [utmi, ulpi] - - snps,quirk-frame-length-adjustment: - description: - Value for GFLADJ_30MHZ field of GFLADJ register for post-silicon frame - length adjustment when the fladj_30mhz_sdbnd signal is invalid or - incorrect. - $ref: /schemas/types.yaml#/definitions/uint32 - minimum: 0 - maximum: 0x3f - - snps,ref-clock-period-ns: - description: - Value for REFCLKPER field of GUCTL register for reference clock period in - nanoseconds, when the hardware set default does not match the actual - clock. - - This binding is deprecated. Instead, provide an appropriate reference clock. - minimum: 8 - maximum: 62 - deprecated: true - - snps,rx-thr-num-pkt: - description: - USB RX packet threshold count. In host mode, this field specifies - the space that must be available in the RX FIFO before the core can - start the corresponding USB RX transaction (burst). - In device mode, this field specifies the space that must be - available in the RX FIFO before the core can send ERDY for a - flow-controlled endpoint. It is only used for SuperSpeed. - The valid values for this field are from 1 to 15. (DWC3 SuperSpeed - USB 3.0 Controller Databook) - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 15 - - snps,rx-max-burst: - description: - Max USB RX burst size. In host mode, this field specifies the - Maximum Bulk IN burst the DWC_usb3 core can perform. When the system - bus is slower than the USB, RX FIFO can overrun during a long burst. - You can program a smaller value to this field to limit the RX burst - size that the core can perform. It only applies to SS Bulk, - Isochronous, and Interrupt IN endpoints in the host mode. - In device mode, this field specifies the NUMP value that is sent in - ERDY for an OUT endpoint. - The valid values for this field are from 1 to 16. (DWC3 SuperSpeed - USB 3.0 Controller Databook) - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - snps,tx-thr-num-pkt: - description: - USB TX packet threshold count. This field specifies the number of - packets that must be in the TXFIFO before the core can start - transmission for the corresponding USB transaction (burst). - This count is valid in both host and device modes. It is only used - for SuperSpeed operation. - Valid values are from 1 to 15. (DWC3 SuperSpeed USB 3.0 Controller - Databook) - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 15 - - snps,tx-max-burst: - description: - Max USB TX burst size. When the system bus is slower than the USB, - TX FIFO can underrun during a long burst. Program a smaller value - to this field to limit the TX burst size that the core can execute. - In Host mode, it only applies to SS Bulk, Isochronous, and Interrupt - OUT endpoints. This value is not used in device mode. - Valid values are from 1 to 16. (DWC3 SuperSpeed USB 3.0 Controller - Databook) - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - snps,rx-thr-num-pkt-prd: - description: - Periodic ESS RX packet threshold count (host mode only). Set this and - snps,rx-max-burst-prd to a valid, non-zero value 1-16 (DWC_usb31 - programming guide section 1.2.4) to enable periodic ESS RX threshold. - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - snps,rx-max-burst-prd: - description: - Max periodic ESS RX burst size (host mode only). Set this and - snps,rx-thr-num-pkt-prd to a valid, non-zero value 1-16 (DWC_usb31 - programming guide section 1.2.4) to enable periodic ESS RX threshold. - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - snps,tx-thr-num-pkt-prd: - description: - Periodic ESS TX packet threshold count (host mode only). Set this and - snps,tx-max-burst-prd to a valid, non-zero value 1-16 (DWC_usb31 - programming guide section 1.2.3) to enable periodic ESS TX threshold. - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - snps,tx-max-burst-prd: - description: - Max periodic ESS TX burst size (host mode only). Set this and - snps,tx-thr-num-pkt-prd to a valid, non-zero value 1-16 (DWC_usb31 - programming guide section 1.2.3) to enable periodic ESS TX threshold. - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 1 - maximum: 16 - - tx-fifo-resize: - description: Determines if the TX fifos can be dynamically resized depending - on the number of IN endpoints used and if bursting is supported. This - may help improve bandwidth on platforms with higher system latencies, as - increased fifo space allows for the controller to prefetch data into its - internal memory. - type: boolean - - tx-fifo-max-num: - description: Specifies the max number of packets the txfifo resizing logic - can account for when higher endpoint bursting is used. (bMaxBurst > 6) The - higher the number, the more fifo space the txfifo resizing logic will - allocate for that endpoint. - $ref: /schemas/types.yaml#/definitions/uint8 - minimum: 3 - - snps,incr-burst-type-adjustment: - description: - Value for INCR burst type of GSBUSCFG0 register, undefined length INCR - burst type enable and INCRx type. A single value means INCRX burst mode - enabled. If more than one value specified, undefined length INCR burst - type will be enabled with burst lengths utilized up to the maximum - of the values passed in this property. - $ref: /schemas/types.yaml#/definitions/uint32-array - minItems: 1 - maxItems: 8 - uniqueItems: true - items: - enum: [1, 4, 8, 16, 32, 64, 128, 256] - - num-hc-interrupters: - maximum: 8 - default: 1 - - port: - $ref: /schemas/graph.yaml#/properties/port - description: - This port is used with the 'usb-role-switch' property to connect the - dwc3 to type C connector. - - ports: - $ref: /schemas/graph.yaml#/properties/ports - description: - Those ports should be used with any connector to the data bus of this - controller using the OF graph bindings specified if the "usb-role-switch" - property is used. - - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: High Speed (HS) data bus. - - port@1: - $ref: /schemas/graph.yaml#/properties/port - description: Super Speed (SS) data bus. - - wakeup-source: - $ref: /schemas/types.yaml#/definitions/flag - description: - Enable USB remote wakeup. - unevaluatedProperties: false required: From patchwork Tue Jan 14 05:11:35 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938403 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 865A3231A48 for ; Tue, 14 Jan 2025 05:05:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831150; cv=none; b=A/kaRV/FU8dL9G6COj2kLoKy7oehgqtLjwVum20CQ1KQVJWk1Ev/VCTy92Lul4Gdp8Nxp2myb2CCiHjwbs+5mAkXZU9IZQqEa0D+/l8ULKbGTNeimzi1rz7aQD8a5xa1/hPaK4apTHdDw2+Ye3+6D/HvNteEH8zGdTTf0c9l/tw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831150; c=relaxed/simple; bh=0VsZDRePzRoN0Q0mxLTGRZ4UObLYSHWuETSTbRWlDng=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VA2LWMaMbl2FCysumwqrTxj/R9FdzB+1ZOtGZU/KDLmBZwnT7jzI3ho42NYF6t3U34gJuiz70QlcU7Ba+weCCelHFbOPNQmHAhytGeaSLjIXY5izdYp5lgPp9cHiZ0ZVbXbzb27K8WOYNH0HpA1ylJPR9B/s4P81z4lA8nXPJIg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=hWVuCk/M; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="hWVuCk/M" Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E27RHi027624 for ; Tue, 14 Jan 2025 05:05:48 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= OBKXeGSZQxrf0jZiT5W1If6viY8DX4hhAQZtfABqOKY=; b=hWVuCk/MAcDYYOvk Ca0WV4aWaPIvdvdpxwf6unx3BiQHGCbZdniMoXV48EuLU4pk91XMDfbzijo2Xvhm E/RjMrRXyz3smxKyk7OezD/9apaQUbBZddHBl+9YvWNEvDd5xYtWenzczfO/cQcm y8Tz4W4adxlyNJ76ETx0Cp+jZ3KAGQyChOVVtdiZMq9V/QeKSfcfPwHTZUsNOc0I JCrDOtN7AorAW8mrCbMdamthEwutU+Rg0vzNTgJwIaZMSJYQhROT/5Ah4xruOQI+ NHaWWezZ0u6IhlgYY2X/rQwq0+RevxFxobWK7t0TZwKz4dk3W/mZ+SsHk3zyMG1x vsJWhg== Received: from mail-ot1-f72.google.com (mail-ot1-f72.google.com [209.85.210.72]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445ev78bca-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:47 +0000 (GMT) Received: by mail-ot1-f72.google.com with SMTP id 46e09a7af769-721b270290aso2715311a34.1 for ; Mon, 13 Jan 2025 21:05:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831146; x=1737435946; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OBKXeGSZQxrf0jZiT5W1If6viY8DX4hhAQZtfABqOKY=; b=QTXuylGNFMg4/q009qLQ3DsqjwX0hiogCkw7tmbu8ipTLWbK6P+WXxpjv/WsTBOq8Z xaa0AKVkdPjQiJ0wMhBQwzNCY2ocDo9n4Bd9zGbJlbpVyXuBiHo2XU/hYkk8/CIBbPC+ 5381uEsB1en6MnoBa6dJjg/9azlklNF2e0m3dz32Pgkbfl95LLVupJojcYF0b47wAhgC p0LqGfdHphJztGfeqPLSMJJcJeCBjkXIO/Pl2+rP1xUXDkI/ZuvKXV95yqfCG8BJUASG MDECsNufhV8PKN3ffNq4ZuNMPG8cXW8wXFUWcAlV4K9c+22p5fdYomLFQxhqkd3KOcLN Z7ug== X-Gm-Message-State: AOJu0YzjDgKcQJ9t205N/ckTZJP9BMiNV5RKl+dWhgo1IB5nWerrBx0G UxPswVSrBXh6jm7xI4R43zxIUaG7oOWaix8C33dKx4e+AA1zGgxmbbbUvuOUPLqUXzGP3uHWnhD d1rTvB8VeNtZ9NH9qcMrtrXLXCvkO+13442/o54aNtsrcpxHR0XgXxad3kM5uECW3 X-Gm-Gg: ASbGnct3oVnx/oQ8NWgYi7DvkfmrSlIAVUaQnxFonOnSGo0+4iN351D5Vivhqdy/HhJ RSSoHCZA4GzSTjAvO6kBSuxBDcVwnFUaIpdS1hqfuNAycyrJ2g0AG0Av77wSugeVBIelYTtinB0 6GZqKr+Zqrz/UzpV3l76RJTEBZin7nl48+BjecM3+M3WQx0cqqdaxr8vyyqxxL2kK89hl2HDzHm ntO8Lep522jySgz8auUqkgIaFEN8wd8SRNGNRqvUOLEI4gH4A6/sncvBNZlT+7iCTjZtC52VJbo aGDQPzxCl93ewrOWaPMCYTLW/Rv12R+3it2bfII4R9ubKhQAdlrLyIw4 X-Received: by 2002:a05:6830:6610:b0:71e:1c5:4f9a with SMTP id 46e09a7af769-721e2ec120amr15921028a34.25.1736831146528; Mon, 13 Jan 2025 21:05:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IF4+Nk9t07KonDc7HgBERD0FxZBuebkIVe6elAiIke+S8IGF9M4H7xgShCXU55t+t36vuhIZA== X-Received: by 2002:a05:6830:6610:b0:71e:1c5:4f9a with SMTP id 46e09a7af769-721e2ec120amr15921011a34.25.1736831146121; Mon, 13 Jan 2025 21:05:46 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:45 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:35 -0800 Subject: [PATCH v3 02/12] dt-bindings: usb: Introduce qcom,snps-dwc3 Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-2-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=19774; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=0VsZDRePzRoN0Q0mxLTGRZ4UObLYSHWuETSTbRWlDng=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIUqc16DJtsGZ7yZYIT6DuPKABUSEfB5+kP4 e62FdnN4peJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFBUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcW3cBAAnn6IzhnsYWOGb/DDEzSdRAEjyuz9OJd7RinV4ni jU6dKufDpuB5Dp5sG9JwsDW5yT+gI17OulVGjM34N3GAzAfK+Y8ZwbwM/clj3guY9qkg2aNC1ok Sl3b22QAF7yqz0rD2l4pnRFlcXmH4huEkNWMfC4fPIoSEFUx8j7EHdZi9peLc3cb6tLeeiYJAHX veRaFqM0FvsAZJxA9mm/4fhg8GCY3iyuq02fKOLZhUyNkQKedODjUvo26mmz3vsLFvlMfjsKrcy 6CvNGIPtJFuO6XsIIdb3fTHXJyMW7whUjtTrA1mOATu0UykUxUw1jU1dxu6gC7vlhAfwrhpvGtB HQd16GjnYBEd6tVgrqGbBndNEasV3YjF0a/OXJUwQ90SN13Yn6RU0ga8bXrw2a1k3XRXMYOSOVE BMNvMbsr6FLhsSQYerWm1V1eel00OxUaLR3odXuTfaa4SlVi/YhTfzm723ZC+vTo7PlNHUDQtMC BvRg9sPypR8smnCkg6zH793x0bTpsf7HOmbRkvvvc9IcsIi+B1S+0diwn1PfsuHXUJKP5IAYBf4 5JcwhoOjPZWGKLx+PaEHD+UxDKugK/uL5x+3UkivPdcoTQl/DjtmH1OuuMb0WPPp3mDIu6ixQPU UCZJqGC0hacrZpdmY28PId/ZUNqWilXIEh7OFbhY4jr8= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: IbrbjN2EqSpNLbD2iIXCBi8m3nBVWOdc X-Proofpoint-GUID: IbrbjN2EqSpNLbD2iIXCBi8m3nBVWOdc X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 spamscore=0 adultscore=0 clxscore=1015 bulkscore=0 mlxscore=0 phishscore=0 mlxlogscore=999 suspectscore=0 lowpriorityscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 The Qualcomm USB glue is not separate of the Synopsys DWC3 core and several of the snps,dwc3 properties (such as clocks and reset) conflicts in expectation with the Qualcomm integration. Using the newly split out Synopsys DWC3 core properties, describe the Qualcomm USB block in a single block. The new binding is a copy of qcom,dwc3 with the needed modifications. It would have been convenient to retain the two structures with the same compatibles, but as there exist no way to select a binding based on the absence of a subnode/patternProperty, a new generic compatible is introduced to describe this binding. To avoid redefining all the platform-specific compatibles, "select" is used to tell the DeviceTree validator which binding to use solely on the generic compatible. (Otherwise if the specific compatible matches during validation, the generic one must match as well) Mark qcom,dwc3 deprecated, to favor expressing future platforms using the new combined binding. Signed-off-by: Bjorn Andersson --- .../devicetree/bindings/usb/qcom,dwc3.yaml | 13 +- .../devicetree/bindings/usb/qcom,snps-dwc3.yaml | 618 +++++++++++++++++++++ 2 files changed, 630 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml b/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml index 8fd02e8aaaa5..09907e492563 100644 --- a/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml +++ b/Documentation/devicetree/bindings/usb/qcom,dwc3.yaml @@ -4,11 +4,22 @@ $id: http://devicetree.org/schemas/usb/qcom,dwc3.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# -title: Qualcomm SuperSpeed DWC3 USB SoC controller +title: Legacy Qualcomm SuperSpeed DWC3 USB SoC controller maintainers: - Wesley Cheng +# Use the combined qcom,snps-dwc3 instead +deprecated: true + +select: + properties: + compatible: + contains: + const: qcom,dwc3 + required: + - compatible + properties: compatible: items: diff --git a/Documentation/devicetree/bindings/usb/qcom,snps-dwc3.yaml b/Documentation/devicetree/bindings/usb/qcom,snps-dwc3.yaml new file mode 100644 index 000000000000..e0369964d495 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/qcom,snps-dwc3.yaml @@ -0,0 +1,618 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/qcom,snps-dwc3.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm SuperSpeed DWC3 USB SoC controller + +maintainers: + - Wesley Cheng + +description: + Describes the Qualcomm USB block, based on Synopsys DWC3. + +select: + properties: + compatible: + contains: + const: qcom,snps-dwc3 + required: + - compatible + +properties: + compatible: + items: + - enum: + - qcom,ipq4019-dwc3 + - qcom,ipq5018-dwc3 + - qcom,ipq5332-dwc3 + - qcom,ipq6018-dwc3 + - qcom,ipq8064-dwc3 + - qcom,ipq8074-dwc3 + - qcom,ipq9574-dwc3 + - qcom,msm8953-dwc3 + - qcom,msm8994-dwc3 + - qcom,msm8996-dwc3 + - qcom,msm8998-dwc3 + - qcom,qcm2290-dwc3 + - qcom,qcs404-dwc3 + - qcom,qcs615-dwc3 + - qcom,qcs8300-dwc3 + - qcom,qdu1000-dwc3 + - qcom,sa8775p-dwc3 + - qcom,sar2130p-dwc3 + - qcom,sc7180-dwc3 + - qcom,sc7280-dwc3 + - qcom,sc8180x-dwc3 + - qcom,sc8180x-dwc3-mp + - qcom,sc8280xp-dwc3 + - qcom,sc8280xp-dwc3-mp + - qcom,sdm660-dwc3 + - qcom,sdm670-dwc3 + - qcom,sdm845-dwc3 + - qcom,sdx55-dwc3 + - qcom,sdx65-dwc3 + - qcom,sdx75-dwc3 + - qcom,sm4250-dwc3 + - qcom,sm6115-dwc3 + - qcom,sm6125-dwc3 + - qcom,sm6350-dwc3 + - qcom,sm6375-dwc3 + - qcom,sm8150-dwc3 + - qcom,sm8250-dwc3 + - qcom,sm8350-dwc3 + - qcom,sm8450-dwc3 + - qcom,sm8550-dwc3 + - qcom,sm8650-dwc3 + - qcom,x1e80100-dwc3 + - const: qcom,snps-dwc3 + + reg: + description: Offset and length of register set for QSCRATCH wrapper + maxItems: 1 + + power-domains: + description: specifies a phandle to PM domain provider node + maxItems: 1 + + required-opps: + maxItems: 1 + + clocks: + description: | + Several clocks are used, depending on the variant. Typical ones are:: + - cfg_noc:: System Config NOC clock. + - core:: Master/Core clock, has to be >= 125 MHz for SS operation and >= + 60MHz for HS operation. + - iface:: System bus AXI clock. + - sleep:: Sleep clock, used for wakeup when USB3 core goes into low + power mode (U3). + - mock_utmi:: Mock utmi clock needed for ITP/SOF generation in host + mode. Its frequency should be 19.2MHz. + minItems: 1 + maxItems: 9 + + clock-names: + minItems: 1 + maxItems: 9 + + iommus: + maxItems: 1 + + resets: + maxItems: 1 + + interconnects: + maxItems: 2 + + interconnect-names: + items: + - const: usb-ddr + - const: apps-usb + + interrupts: + description: | + Different types of interrupts are used based on HS PHY used on target: + - dwc_usb3: Core DWC3 interrupt + - pwr_event: Used for wakeup based on other power events. + - hs_phy_irq: Apart from DP/DM/QUSB2 PHY interrupts, there is + hs_phy_irq which is not triggered by default and its + functionality is mutually exclusive to that of + {dp/dm}_hs_phy_irq and qusb2_phy_irq. + - qusb2_phy: SoCs with QUSB2 PHY do not have separate DP/DM IRQs and + expose only a single IRQ whose behavior can be modified + by the QUSB2PHY_INTR_CTRL register. The required DPSE/ + DMSE configuration is done in QUSB2PHY_INTR_CTRL register + of PHY address space. + - {dp/dm}_hs_phy_irq: These IRQ's directly reflect changes on the DP/ + DM pads of the SoC. These are used for wakeup + only on SoCs with non-QUSB2 targets with + exception of SDM670/SDM845/SM6350. + - ss_phy_irq: Used for remote wakeup in Super Speed mode of operation. + minItems: 3 + maxItems: 19 + + interrupt-names: + minItems: 3 + maxItems: 19 + + qcom,select-utmi-as-pipe-clk: + description: + If present, disable USB3 pipe_clk requirement. + Used when dwc3 operates without SSPHY and only + HS/FS/LS modes are supported. + type: boolean + + wakeup-source: true + +# Required child node: + +required: + - compatible + - reg + - clocks + - clock-names + - interrupts + - interrupt-names + +allOf: + - $ref: snps,dwc3-common.yaml# + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq4019-dwc3 + - qcom,ipq5332-dwc3 + then: + properties: + clocks: + maxItems: 3 + clock-names: + items: + - const: core + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq8064-dwc3 + then: + properties: + clocks: + items: + - description: Master/Core clock, has to be >= 125 MHz + for SS operation and >= 60MHz for HS operation. + clock-names: + items: + - const: core + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq9574-dwc3 + - qcom,msm8953-dwc3 + - qcom,msm8996-dwc3 + - qcom,msm8998-dwc3 + - qcom,qcs8300-dwc3 + - qcom,sa8775p-dwc3 + - qcom,sc7180-dwc3 + - qcom,sc7280-dwc3 + - qcom,sdm670-dwc3 + - qcom,sdm845-dwc3 + - qcom,sdx55-dwc3 + - qcom,sdx65-dwc3 + - qcom,sdx75-dwc3 + - qcom,sm6350-dwc3 + then: + properties: + clocks: + maxItems: 5 + clock-names: + items: + - const: cfg_noc + - const: core + - const: iface + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq6018-dwc3 + then: + properties: + clocks: + minItems: 3 + maxItems: 4 + clock-names: + oneOf: + - items: + - const: core + - const: sleep + - const: mock_utmi + - items: + - const: cfg_noc + - const: core + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq8074-dwc3 + - qcom,qdu1000-dwc3 + then: + properties: + clocks: + maxItems: 4 + clock-names: + items: + - const: cfg_noc + - const: core + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq5018-dwc3 + - qcom,msm8994-dwc3 + - qcom,qcs404-dwc3 + then: + properties: + clocks: + maxItems: 4 + clock-names: + items: + - const: core + - const: iface + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,sc8280xp-dwc3 + - qcom,sc8280xp-dwc3-mp + - qcom,x1e80100-dwc3 + - qcom,x1e80100-dwc3-mp + then: + properties: + clocks: + maxItems: 9 + clock-names: + items: + - const: cfg_noc + - const: core + - const: iface + - const: sleep + - const: mock_utmi + - const: noc_aggr + - const: noc_aggr_north + - const: noc_aggr_south + - const: noc_sys + + - if: + properties: + compatible: + contains: + enum: + - qcom,sdm660-dwc3 + then: + properties: + clocks: + minItems: 4 + maxItems: 5 + clock-names: + oneOf: + - items: + - const: cfg_noc + - const: core + - const: iface + - const: sleep + - const: mock_utmi + - items: + - const: cfg_noc + - const: core + - const: sleep + - const: mock_utmi + + - if: + properties: + compatible: + contains: + enum: + - qcom,qcm2290-dwc3 + - qcom,qcs615-dwc3 + - qcom,sar2130p-dwc3 + - qcom,sc8180x-dwc3 + - qcom,sc8180x-dwc3-mp + - qcom,sm6115-dwc3 + - qcom,sm6125-dwc3 + - qcom,sm8150-dwc3 + - qcom,sm8250-dwc3 + - qcom,sm8450-dwc3 + - qcom,sm8550-dwc3 + - qcom,sm8650-dwc3 + then: + properties: + clocks: + minItems: 6 + clock-names: + items: + - const: cfg_noc + - const: core + - const: iface + - const: sleep + - const: mock_utmi + - const: xo + + - if: + properties: + compatible: + contains: + enum: + - qcom,sm8350-dwc3 + then: + properties: + clocks: + minItems: 5 + maxItems: 6 + clock-names: + minItems: 5 + items: + - const: cfg_noc + - const: core + - const: iface + - const: sleep + - const: mock_utmi + - const: xo + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq5018-dwc3 + - qcom,ipq6018-dwc3 + - qcom,ipq8074-dwc3 + - qcom,msm8953-dwc3 + - qcom,msm8998-dwc3 + then: + properties: + interrupts: + minItems: 3 + maxItems: 4 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event + - const: qusb2_phy + - const: ss_phy_irq + + - if: + properties: + compatible: + contains: + enum: + - qcom,msm8996-dwc3 + - qcom,qcs404-dwc3 + - qcom,sdm660-dwc3 + - qcom,sm6115-dwc3 + - qcom,sm6125-dwc3 + then: + properties: + interrupts: + minItems: 4 + maxItems: 5 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event + - const: qusb2_phy + - const: hs_phy_irq + - const: ss_phy_irq + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq5332-dwc3 + then: + properties: + interrupts: + maxItems: 4 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event + - const: dp_hs_phy_irq + - const: dm_hs_phy_irq + + - if: + properties: + compatible: + contains: + enum: + - qcom,x1e80100-dwc3 + then: + properties: + interrupts: + maxItems: 5 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event + - const: dp_hs_phy_irq + - const: dm_hs_phy_irq + - const: ss_phy_irq + + - if: + properties: + compatible: + contains: + enum: + - qcom,ipq4019-dwc3 + - qcom,ipq8064-dwc3 + - qcom,msm8994-dwc3 + - qcom,qcs615-dwc3 + - qcom,qcs8300-dwc3 + - qcom,qdu1000-dwc3 + - qcom,sa8775p-dwc3 + - qcom,sc7180-dwc3 + - qcom,sc7280-dwc3 + - qcom,sc8180x-dwc3 + - qcom,sc8280xp-dwc3 + - qcom,sdm670-dwc3 + - qcom,sdm845-dwc3 + - qcom,sdx55-dwc3 + - qcom,sdx65-dwc3 + - qcom,sdx75-dwc3 + - qcom,sm4250-dwc3 + - qcom,sm6350-dwc3 + - qcom,sm8150-dwc3 + - qcom,sm8250-dwc3 + - qcom,sm8350-dwc3 + - qcom,sm8450-dwc3 + - qcom,sm8550-dwc3 + - qcom,sm8650-dwc3 + then: + properties: + interrupts: + minItems: 5 + maxItems: 6 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event + - const: hs_phy_irq + - const: dp_hs_phy_irq + - const: dm_hs_phy_irq + - const: ss_phy_irq + + - if: + properties: + compatible: + contains: + enum: + - qcom,sc8180x-dwc3-mp + - qcom,x1e80100-dwc3-mp + then: + properties: + interrupts: + minItems: 11 + maxItems: 11 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event_1 + - const: pwr_event_2 + - const: hs_phy_1 + - const: hs_phy_2 + - const: dp_hs_phy_1 + - const: dm_hs_phy_1 + - const: dp_hs_phy_2 + - const: dm_hs_phy_2 + - const: ss_phy_1 + - const: ss_phy_2 + + - if: + properties: + compatible: + contains: + enum: + - qcom,sc8280xp-dwc3-mp + then: + properties: + interrupts: + minItems: 19 + maxItems: 19 + interrupt-names: + items: + - const: dwc_usb3 + - const: pwr_event_1 + - const: pwr_event_2 + - const: pwr_event_3 + - const: pwr_event_4 + - const: hs_phy_1 + - const: hs_phy_2 + - const: hs_phy_3 + - const: hs_phy_4 + - const: dp_hs_phy_1 + - const: dm_hs_phy_1 + - const: dp_hs_phy_2 + - const: dm_hs_phy_2 + - const: dp_hs_phy_3 + - const: dm_hs_phy_3 + - const: dp_hs_phy_4 + - const: dm_hs_phy_4 + - const: ss_phy_1 + - const: ss_phy_2 + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + soc { + #address-cells = <2>; + #size-cells = <2>; + + usb@a600000 { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0x100000>; + + clocks = <&gcc GCC_CFG_NOC_USB3_PRIM_AXI_CLK>, + <&gcc GCC_USB30_PRIM_MASTER_CLK>, + <&gcc GCC_AGGRE_USB3_PRIM_AXI_CLK>, + <&gcc GCC_USB30_PRIM_SLEEP_CLK>, + <&gcc GCC_USB30_PRIM_MOCK_UTMI_CLK>; + clock-names = "cfg_noc", + "core", + "iface", + "sleep", + "mock_utmi"; + + assigned-clocks = <&gcc GCC_USB30_PRIM_MOCK_UTMI_CLK>, + <&gcc GCC_USB30_PRIM_MASTER_CLK>; + assigned-clock-rates = <19200000>, <150000000>; + + interrupts = , + , + , + , + , + ; + interrupt-names = "dwc_usb3", "pwr_event", "hs_phy_irq", + "dp_hs_phy_irq", "dm_hs_phy_irq", "ss_phy_irq"; + + power-domains = <&gcc USB30_PRIM_GDSC>; + + resets = <&gcc GCC_USB30_PRIM_BCR>; + + iommus = <&apps_smmu 0x740 0>; + snps,dis_u2_susphy_quirk; + snps,dis_enblslpm_quirk; + phys = <&usb_1_hsphy>, <&usb_1_ssphy>; + phy-names = "usb2-phy", "usb3-phy"; + }; + }; +... From patchwork Tue Jan 14 05:11:36 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938405 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 88CD11B4159 for ; Tue, 14 Jan 2025 05:05:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831152; cv=none; b=b+L7bSNCexjKvn+F/AWUCm5CtelL6S3A6iwpjBWjja7cyThiuWGUxb9alAi4dBlkX7bZn6hGESRC7oXVkhKKy/o8MxmVJtDcXvAL1RB4oyOEHrQdXtFqJFjV0UHM0IxhSP3EXL3fd4POWlzNS6RD4cN29k/IKEHhCx3qyZ6XcjQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831152; c=relaxed/simple; bh=cEWULSiGoWIr4uAoz57xnHYom3cCE6za+4sS6e97+6E=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Tqaju4ErOnyi6Ffq7kd2d0SUN0iPVwe6XtTDDlPZ/VeXklhLZ0n+rMtoHsA78n9v+4tQexbetlLLnXN1f9hizyiWJA0/Zy1my4cCywjMmSpFMyC6COYhcnuurBdHKlUELDWg+xuz+MUpgKpH/oK5/b6KIzgLsj3LhzEdmQ8Pt/0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=J1kTa67A; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="J1kTa67A" Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DJLYeb002841 for ; Tue, 14 Jan 2025 05:05:48 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= +VkUXrOLcLDpSxofU5hRKw+Y1fiuNviLtTxMsES8ipI=; b=J1kTa67A9rOEL9kr o+gjpSXV4RpgrN23L6Gs52iqfVyQ11AR/JyWCmMg/xawhLDOsulFRL2LdLjITnqq 0RgIcuwOLYth9Q9yWRTrGJIp1ikXoHOkLY98F+SrN9MXZhRD3FtCOmvvIRtbmtC/ h+a85Orzjm+1ETpHZr82/NDR14DSz7pquJqldnGbEwjJEUoAy2IaYfbg3f+FB44z ZUlfX7fLZVKbnZtGpV8Rt162tDgv3DHpA3GR+ZVe8kepjfFjb7Pju5mU8Bn6WDWK DcJzRr+5jtftOy/pZ92Klj+hlnlhGjNsELW77HGmgj3u3kbvVpgVOC2obR/WrsJt tp7eUQ== Received: from mail-oi1-f197.google.com (mail-oi1-f197.google.com [209.85.167.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4458ww92cq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:48 +0000 (GMT) Received: by mail-oi1-f197.google.com with SMTP id 5614622812f47-3eee0e2a528so4077042b6e.1 for ; Mon, 13 Jan 2025 21:05:48 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831147; x=1737435947; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+VkUXrOLcLDpSxofU5hRKw+Y1fiuNviLtTxMsES8ipI=; b=bl2hktK48lDdICSN2viC/GPswmEUMp+6F5yFiQlVdOzXgfksEaWR3Hk4hIG+VcEA1M JER8XUPZUm0qt4iH2tKznqlq6nBWwUT/YWRBbrJlIECq86KhP7OxnvLdsQvAPI7te9IV DTaB+Jg1Ox9/07SdTPUhZHtE4gZ6RKcr02+qOFF6dHpbDNUd0/jxVAU0EPC5Akp0E2NB I4arAJhDvIxSTpZiUBkaFsAyoNCq4GKu/7avJZzXURttMioUd3bqd1Cb2iEzxi2XvodF /EUSwezH2mT+BkVPPzQpf5YQz2cPoFW4p3SDy/y0B/lJwroIesLBLvgm+MOLxwI23v/+ AA9w== X-Gm-Message-State: AOJu0YzrmkhQ7+OiCuK+r4Fmvri4sYsYarPzZamDK1jfY9hMCGQWJHCy 5tNNI8sunQTHV2KieFBQnSPwlu+E6dxorf8qWKl95dJGMyYDs9xHCbuBXlCtb46DXZQAM3WFtzm wYT+DNX/osF43ZfBDguF7+C3vx9ViNbtmlgnsHc0jTOHBnySewo1KDckgO8XkN9sk X-Gm-Gg: ASbGncss1AWUdvuoxslz3anlf4k/KwDiNi5BNqJR1pSnj8E6R0mPQkEc7puKgvNJ4GE CWFJsLMQNV2z3MAUrRZ22z0HlFEy9hHXsS0TxCjZ6rxVDWXAVPuzGapkGOP/j21rVlNYDiMVtKr 0y+DoYpuRHsC4V48CkFOL8/iolgYEr2x1xwfoW3+rRC7IxxzZz+NpYJPqTGskBMwQ9q6rgSFd2y LNBd5a1BgbLPqmea560MyKO7hbmCTFbJkHGGPTokJdy2HsRfuJd7nu/B5B2AHcLb+a+UNjr2MnL A2GoN3a9/eqUFD6E0V4pXfV9ORLXH5kff99zlQZC3Abdy/3/HwcGuo9c X-Received: by 2002:a05:6808:6396:b0:3f0:e42:4dab with SMTP id 5614622812f47-3f00e425c3bmr9849861b6e.33.1736831147407; Mon, 13 Jan 2025 21:05:47 -0800 (PST) X-Google-Smtp-Source: AGHT+IF48gmKNJ7kvN2MsPkkY4TVIyrGT0lQ2sF5JyRVS+J4uOenMZH+1AAMJf2LdNd32YErsixZcw== X-Received: by 2002:a05:6808:6396:b0:3f0:e42:4dab with SMTP id 5614622812f47-3f00e425c3bmr9849852b6e.33.1736831147117; Mon, 13 Jan 2025 21:05:47 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:46 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:36 -0800 Subject: [PATCH v3 03/12] of: dynamic: Add of_changeset_add_prop_copy() Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-3-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2203; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=cEWULSiGoWIr4uAoz57xnHYom3cCE6za+4sS6e97+6E=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVESRHXDU5xGo0wLQM+Yn/AExNqBNW8EdSt NuzfG1DIU2JAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcVWhw//WKnIBpDCTavyrPXwLpmezKe+u3AEL2Ncbr4RQMx bCAeTAdvL/tJh9aYXQTsQb2W9HEpjgAzLYdg6XYd6T5TlZoMLH13WQyKlpruTtQ7DweN8YH451D 3BYwQbPqOVOBKSgg3xU/jNUgY44U0eidfat/m4bXm/c8kC+HUdygPSj20S3BSrmFfIW9peE0u/t Z2E1plVpFMuOkYHvIYRBN1T5n0h72UiwReUPETMbHhIk4LJGy7okp57usO1sSQ5KEXyRj2LUEjU s/jebX1avnVzryHlXKTMLPjA9n7BBN8uMq1bJskRW0lJKlUkiBZqlJVShhboUmv4FFJSsBuDtGG 1u5SkgfK6O3mpWbEbAyD1aFsfudmwaGbYonENWUM3MjIg5GOMpbJv10nQUcn95V9z80xuTQ3T5U cw5JouNJWrhGVnt4i80hse4+AFWdhXzj3hGSypc3tGFm73Slug421961CXYE6HDmFYe/CjR53Ny i52SqwtxKfBw1p+tgNacPTUq3n3R/Uq1qxSOrXDz0jTlNecpdw1GmlxYYtbCjG95ivcPNED7t0n nDGw5t6B3RGZu1FpTv16I8aKIrNHfgtqOVDtojh30yyiJCadyUkv4567wkaquHtX2LwzMacJbF8 tGf07oz+iMfexBd4Y87FK6JjetCVdN+TxK3O6Mhz4EWY= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: YoZVnfjGKwhvbrmGfgD3QrJWFWzqm0GQ X-Proofpoint-ORIG-GUID: YoZVnfjGKwhvbrmGfgD3QrJWFWzqm0GQ X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 spamscore=0 mlxlogscore=999 mlxscore=0 clxscore=1015 impostorscore=0 malwarescore=0 adultscore=0 bulkscore=0 phishscore=0 suspectscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 When implementing migration between bindings with different structure, properties might move from one node to another. Introduce a helper function to do this, releaving the caller from having to care about the datatype of the property and/or peek into the struct property. Signed-off-by: Bjorn Andersson --- drivers/of/dynamic.c | 20 ++++++++++++++++++++ include/linux/of.h | 3 +++ 2 files changed, 23 insertions(+) diff --git a/drivers/of/dynamic.c b/drivers/of/dynamic.c index 0aba760f7577..e4d7ff53a892 100644 --- a/drivers/of/dynamic.c +++ b/drivers/of/dynamic.c @@ -1073,6 +1073,26 @@ int of_changeset_add_prop_bool(struct of_changeset *ocs, struct device_node *np, } EXPORT_SYMBOL_GPL(of_changeset_add_prop_bool); +/** + * of_changeset_add_prop_copy() - Add a property with name and value copied + * from an existing property, to a changeset. + * + * @ocs: changeset pointer + * @np: device node pointer + * @prop: existing property to copy + * + * Create a new property with name and value copied from a provided property, + * to a changeset. + * + * Return: 0 on success, a negative error value in case of an error. + */ +int of_changeset_add_prop_copy(struct of_changeset *ocs, struct device_node *np, + const struct property *prop) +{ + return of_changeset_add_prop_helper(ocs, np, prop); +} +EXPORT_SYMBOL_GPL(of_changeset_add_prop_copy); + static int of_changeset_update_prop_helper(struct of_changeset *ocs, struct device_node *np, const struct property *pp) diff --git a/include/linux/of.h b/include/linux/of.h index f921786cb8ac..6a9bcdf9d629 100644 --- a/include/linux/of.h +++ b/include/linux/of.h @@ -1667,6 +1667,9 @@ int of_changeset_update_prop_string(struct of_changeset *ocs, int of_changeset_add_prop_bool(struct of_changeset *ocs, struct device_node *np, const char *prop_name); +int of_changeset_add_prop_copy(struct of_changeset *ocs, struct device_node *np, + const struct property *prop); + #else /* CONFIG_OF_DYNAMIC */ static inline int of_reconfig_notifier_register(struct notifier_block *nb) { From patchwork Tue Jan 14 05:11:37 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938407 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 901C523497C for ; Tue, 14 Jan 2025 05:05:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831154; cv=none; b=gTr3eKCc6K2QhObhdB1K2E91XDDjIs52W61atiwoD1IY7QgsHlsOVHxuN7zuLUwUVO9AnAsigG2bIzgP2AmlzVIcPd5bf5EowWic7plu/gB4KVZWQM/izPY4aVNwbldoUjPBTg/rlQsf8Yg4x92v+8DjIUYk3sTLsOuGhhRiack= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831154; c=relaxed/simple; bh=+7T+W0npzIsClEByBimGQWCrPRhW5Rfaa7ea0jwJn8U=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=dT/4z+MiWLKk/VrWEUbz72pG//A8AXinqaAHWBGFZuMsJaLPNNn1zKz4xcxf3OWLCR5p0bbWS/fSxGcVVbeTOTfsEGmNIcsH+Tr4XsQiz3PwlzFsEYiX+p/srgsdcogUyiQcY+AQicGnUKBoeQNHM88wo/b4yNIUBe8suK/f9FA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=k69kXcRx; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="k69kXcRx" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DKsOmB026165 for ; Tue, 14 Jan 2025 05:05:50 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= U+2fy3/LK/7hee4NhdhsAUZpisJu9Q29FyDFunFTLIA=; b=k69kXcRxfiRRI5Nc RpNKXv1rXYeBjOR2vHl9buk0+l7fhlwMXY0HPW86wCSPJtTUqBNrKjeE0VSgu0/U HW0KrLbRKQzky0SVy0VckqE7YgLtlkEuLvBaWsQ5GCb9yCvDrASczpfpNXoXRY3B WNdt2vDrdgLxRaetk7dTUNly9RHiZKYIfGWDKIfmvygDwJNXfDuHueK2ExOoEWWr KQ2gQCLhs0PRpXxbxKekApx/GQR9eRocbg3HyhEzF2fXV7kLy+CT1IMG3QdXHysf zfqkCUib5I2hlyfY7sCD0WGN/ubU9j3CMCjmllX+IWJUey/FGm6c3RCb97Hmvynk OSWotw== Received: from mail-ot1-f70.google.com (mail-ot1-f70.google.com [209.85.210.70]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445a928v6j-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:49 +0000 (GMT) Received: by mail-ot1-f70.google.com with SMTP id 46e09a7af769-71fc1df4bb5so3044219a34.3 for ; Mon, 13 Jan 2025 21:05:49 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831148; x=1737435948; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=U+2fy3/LK/7hee4NhdhsAUZpisJu9Q29FyDFunFTLIA=; b=WxpJFCGqWFOPksc62284nDQ6fBEu2rXyf0byiRxCwb9MruBm4EfV+5FDzdHUorPk6v xqXAOADCU2zJ9s4uhZpp42RYf/zttey1m8j9kSHdyxkiD2IHlu0RJNJeBmV7E4pwCeDk xarrSE3fOPnhtWKlCvm3ZCyL46MmDrnDu3N+/NfKVLJnZ9OXcLCa3dWV7IMEZOAACZvu FIwdAI6tHmyv03AVQYduBoa9SIYG7j8MLJ4dIVfWxbxoQuIsJlr061Htk+EUsR8QQ2dz dYrfiElOmiidgupypbjeXI1L5uz1PFhjjMfKMZYhsdGFrTQTTgrBzDuwO/6SaUBr9ovB i5jA== X-Gm-Message-State: AOJu0YyreOjruspPJC5UU/FlsKRviqNlqPKFzXCMCVe/olTieiu9BN7L RuJOQyJZor7xGLnqEzmjQYWk+D/hVWoSSeqRHbuK9qnyk23tw9/EeMfKt6pXeJ5lKZPlnmkk75/ j6tER4Wfn0+BkvrITo7jz6KiFfawoXhRpubvuBBUC+GAdrUvnvRcvtxaV4/xBMK6I X-Gm-Gg: ASbGncu4Ex+QzCSvSn6Gf8YDVre/0EtrtDNPLpgG2a0tXf+fn0hcMK/s9RVzINDUJ2N W9WmF+4DmNEfYRUlHNyTd8Bn8CiJZC/+hK8tES4tJyksQ751p5eyjypYxBa8KTBw4FhMYzFTWzm 9UtC0TeX1EATGkB67Jg9vB+Hm6zrWy657e9xdVbDkqjOP7M+Midw/5l0APqAAAJcG1r1aYkN9wJ y3578uAuCYgS+75648v4PI4h0eMEYxYH/2oFq0qfH0/jl8L1N3KW/ng+yCTvnpFj+sAk4udFFAG CHCvlEABQI1k6fErH1kL56zuFSBOFcFDiSr44+IlLlCnqNcuWE2l5AcP X-Received: by 2002:a05:6830:678e:b0:71d:fc52:1ab6 with SMTP id 46e09a7af769-721e2e9b660mr15257970a34.23.1736831148571; Mon, 13 Jan 2025 21:05:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IE/kSyD1OtHatXV7bU0pa748PZBDxc+nss+I9GrvkOdP+CQM86cfz3KVsLY33vBqQgvSikgPw== X-Received: by 2002:a05:6830:678e:b0:71d:fc52:1ab6 with SMTP id 46e09a7af769-721e2e9b660mr15257954a34.23.1736831148185; Mon, 13 Jan 2025 21:05:48 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:47 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:37 -0800 Subject: [PATCH v3 04/12] of: overlays: Introduce dwc3 flattening overlay Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-4-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=9764; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=+7T+W0npzIsClEByBimGQWCrPRhW5Rfaa7ea0jwJn8U=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVTsZSh8RjRlN+dbQqiOg8NYoBdj/N1uddm jbR50VoHwWJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcWHBw//ToyOtUUtb89CwegfxOWVuB3g+E27cz2uh5LRfq/ W3xB+SzgrbG8yeSAl+y/l0zKHBuxm534IzO/umvAees0CkjG+MFCc1QUhmrmRxBTw+5i8O4EB4Q 9oLJknrVo71huV0QY6lJCxDtrvDm5u7UvF2Vn0OPQfiEh3c/uRIXFZrYffIZiazcxDrk3TlD51U 52iXw8MHk2v0QKFpm6NjgpaKVey4xV1xizq1mxueIh04GJBRG0eswPtLE5OCiSVetq2p+ZmBEfu fjic6gptxZF5QEW9K7j1LQR/hEhFc7MZP7foxTGoMinZYOWjXoXnMbxtodT3P2aCPAZRFn0ISTy LraSnhaJjb1fhxlxob5w5LZvjT48iJ2BP1OGPe2BU2FN4HLeN3OCwEwdO1gU6bL+UpDwKFlatlm FeCePzfKI5egz+CqaRhQvWHMGOYiYiX90r5TJl/5/wsviybgakCEOYk8LGZpfSZOFKCHvv93gFw s7i7iKEEZbAAFDMzl1zA+D2l/RMqBQqAT3YKa4/u/ydmqyoe/nH7IEV09n5uLyZNsZGnfljyWO5 Zv+EQP1EqMpolFfJ3NWP3wg6bGEEMdVv+XDkTBy8pchMDkuqRajAhijJjJksxpTmBSdc2IHTIu5 Uzu9oFQdayCp3d/QYNUL7NSKuxUgoRSWYvorsoGultIA= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: C2p0cwzNi6Lnxmcc4DLJ6DN1LEisW9Tl X-Proofpoint-ORIG-GUID: C2p0cwzNi6Lnxmcc4DLJ6DN1LEisW9Tl X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 malwarescore=0 suspectscore=0 impostorscore=0 adultscore=0 priorityscore=1501 spamscore=0 lowpriorityscore=0 clxscore=1015 mlxlogscore=999 phishscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 The Synopsys DWC3 core is often found together with vendor glue logic. While being a single piece of hardware this has been expressed as two independent (although with parent/child relationship) nodes in DeviceTree - but they are not separate components, and the separation prevents implementation of certain features (such as role switching, when this involved both parts). The newly introduced qcom,snps-dwc3 binding changes this representation of the Qualcomm implementation to a single node, and in an upcoming change the implementation follows suite - combining the two separate drivers into a single device instance. In order to avoid two separate implementations of the Qualcomm DWC3 glue driver, and/or continue to live with the documented race conditions in the driver, the driver will be changed to only operate on the new - flattened - DeviceTree binding. As both the Qualcomm glue driver and the dwc3 core driver is parsing DeviceTree, the only sensible way to handle this - while maintaining backwards compatibility with exiting DeviceTree blobs, is to convert the representation at runtime. The conversion between qcom,dwc3 and qcom,snps-dwc3 is performed here in the form of an independent overlay-based mechanism, to avoid sprinkling DeviceTree-translation code into the glue driver, which over time is expected to allow hiding some internals of the OF-code. But this should also make it suitable for other (than Qualcomm) vendors to reuse the translation logic as they flatten their glue/dwc3 implementations. The migration is implemented using two steps: 1) SoC/board integration is migrated using embedded overlays, which are applied based on machine compatible matching. This handles the complex cases such as merging "reg" and "interrupt" properties. 2) Standard snps properties, which might be board-specific, are migrated using of_changeset logic. Notably the of_graph is migrated this way, to avoid having to provide overlays for every single board dtb out there. The migration code can only be enabled once the dwc3 glue driver supports the new binding, but in order to avoid having to support both bindings in the dwc3 glue a kill-switch is left in place, to be removed at the instant the driver is converted. The newly introduced Kconfig option is defaulted to follow USB_DWC3_QCOM in order to maximize the chances of people not losing USB functionality in defconfig or distro builds. Over time this can probably be phased out, followed by the overlay solution itself. Signed-off-by: Bjorn Andersson --- drivers/of/Kconfig | 2 + drivers/of/Makefile | 2 + drivers/of/overlays/Kconfig | 15 ++ drivers/of/overlays/Makefile | 3 + drivers/of/overlays/dwc3-flattening/Makefile | 4 + .../of/overlays/dwc3-flattening/dwc3-flattening.c | 160 +++++++++++++++++++++ .../of/overlays/dwc3-flattening/dwc3-flattening.h | 7 + 7 files changed, 193 insertions(+) diff --git a/drivers/of/Kconfig b/drivers/of/Kconfig index 50697cc3b07e..b5f3cd69bad9 100644 --- a/drivers/of/Kconfig +++ b/drivers/of/Kconfig @@ -126,4 +126,6 @@ config OF_OVERLAY_KUNIT_TEST config OF_NUMA bool +source "drivers/of/overlays/Kconfig" + endif # OF diff --git a/drivers/of/Makefile b/drivers/of/Makefile index 379a0afcbdc0..1ff9d0befb38 100644 --- a/drivers/of/Makefile +++ b/drivers/of/Makefile @@ -25,3 +25,5 @@ obj-$(CONFIG_OF_OVERLAY_KUNIT_TEST) += overlay-test.o overlay-test-y := overlay_test.o kunit_overlay_test.dtbo.o obj-$(CONFIG_OF_UNITTEST) += unittest-data/ + +obj-y += overlays/ diff --git a/drivers/of/overlays/Kconfig b/drivers/of/overlays/Kconfig new file mode 100644 index 000000000000..8f07e6db3dc3 --- /dev/null +++ b/drivers/of/overlays/Kconfig @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: GPL-2.0 + +config OF_OVERLAYS_DWC3_FLATTENING + bool "DeviceTree overlay for migrating DWC3 glue bindings" + depends on OF + select OF_DYNAMIC + select OF_OVERLAY + default USB_DWC3_QCOM + help + This option enables the migration of the loaded DeviceTree from the + binding that splits DWC3 representation in glue and core nodes (such + as "qcom,dwc3"), to the unified binding ("qcom,snps-dwc3"). + + Enable this if you intend to boot the Linux kernel on a system with a + DeviceTree blob using the non-flattened binding. diff --git a/drivers/of/overlays/Makefile b/drivers/of/overlays/Makefile new file mode 100644 index 000000000000..44dd5c09ac8d --- /dev/null +++ b/drivers/of/overlays/Makefile @@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-$(CONFIG_OF_OVERLAYS_DWC3_FLATTENING) += dwc3-flattening/ diff --git a/drivers/of/overlays/dwc3-flattening/Makefile b/drivers/of/overlays/dwc3-flattening/Makefile new file mode 100644 index 000000000000..78ed59517887 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/Makefile @@ -0,0 +1,4 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-$(CONFIG_OF_OVERLAYS_DWC3_FLATTENING) += dwc3-flattening-overlay.o +dwc3-flattening-overlay-y += dwc3-flattening.o diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c new file mode 100644 index 000000000000..fe8e42627fe3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c @@ -0,0 +1,160 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright (c) 2025, Qualcomm Innovation Center, Inc. All rights reserved. + */ + +#define pr_fmt(fmt) "dwc3-flattening: " fmt + +#include +#include +#include +#include "dwc3-flattening.h" + +struct dwc3_overlay_symbol { + const char *symbol; + const char *path; +}; + +struct dwc3_overlay_data { + const void *fdt; + const void *end; + const char *migrate_match; +}; + +static const struct of_device_id dwc3_flatten_of_match[] = { + {} +}; + +static int dwc3_flattening_copy_snps_properties(struct of_changeset *ocs, + struct device_node *np, + struct device_node *dwc3) +{ + struct property *prop; + int ret = 0; + + for_each_property_of_node(dwc3, prop) { + if (strncmp(prop->name, "snps,", 5) && + strcmp(prop->name, "usb-role-switch") && + strcmp(prop->name, "dr_mode") && + strcmp(prop->name, "tx-fifo-resize") && + strcmp(prop->name, "maximum-speed")) + continue; + + ret = of_changeset_add_prop_copy(ocs, np, prop); + if (ret) + break; + } + + return ret; +} + +static int dwc3_flattening_copy_ports_tree(struct of_changeset *ocs, + struct device_node *new_parent, + struct device_node *old_node) +{ + struct device_node *new_node; + struct property *prop; + int ret; + + new_node = of_changeset_create_node(ocs, new_parent, old_node->full_name); + if (!new_node) + return -ENOMEM; + + for_each_property_of_node(old_node, prop) { + of_changeset_add_prop_copy(ocs, new_node, prop); + } + + for_each_child_of_node_scoped(old_node, child) { + ret = dwc3_flattening_copy_ports_tree(ocs, new_node, child); + if (ret) + return ret; + } + + return of_changeset_detach_node(ocs, old_node); +} + +static int dwc3_flattening_migrate(struct of_changeset *ocs, + struct device_node *np) +{ + struct device_node *ports; + struct device_node *dwc3; + int ret; + + dwc3 = of_get_compatible_child(np, "snps,dwc3"); + if (!dwc3) + return 0; + + ret = dwc3_flattening_copy_snps_properties(ocs, np, dwc3); + if (ret) { + pr_err("failed to copy properties of %pOF", dwc3); + goto out; + } + + ports = of_get_child_by_name(dwc3, "ports"); + if (ports) { + ret = dwc3_flattening_copy_ports_tree(ocs, np, ports); + of_node_put(ports); + if (ret) { + pr_err("failed to clone ports child of %pOF", dwc3); + goto out; + } + } + + ret = of_changeset_detach_node(ocs, dwc3); + +out: + of_node_put(dwc3); + + return ret; +} + +static int dwc3_flattening_init(void) +{ + const struct dwc3_overlay_data *data; + const struct of_device_id *match; + struct of_changeset migrate_ocs; + struct device_node *np; + int overlay_ovcs; + int ret; + + /* TODO: Remove kill-switch as dwc3-qcom is migrated to qcom,snps-dwc */ + return 0; + + match = of_match_node(dwc3_flatten_of_match, of_root); + if (!match) + return 0; + + data = match->data; + + np = of_find_compatible_node(NULL, NULL, data->migrate_match); + if (!np) { + pr_debug("already applied\n"); + return 0; + } + of_node_put(np); + + of_changeset_init(&migrate_ocs); + for_each_compatible_node(np, NULL, data->migrate_match) { + ret = dwc3_flattening_migrate(&migrate_ocs, np); + if (ret < 0) { + of_node_put(np); + goto out_migrate_destroy; + } + } + + ret = of_changeset_apply(&migrate_ocs); + if (ret < 0) + goto out_migrate_destroy; + + ret = of_overlay_fdt_apply(data->fdt, data->end - data->fdt, &overlay_ovcs, NULL); + if (ret < 0) { + of_overlay_remove(&overlay_ovcs); + of_changeset_revert(&migrate_ocs); + } + +out_migrate_destroy: + of_changeset_destroy(&migrate_ocs); + + return ret; +} +postcore_initcall(dwc3_flattening_init); diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h new file mode 100644 index 000000000000..6147376d3c92 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h @@ -0,0 +1,7 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef __DWC3_FLATTENING_H__ +#define __DWC3_FLATTENING_H__ + +#include + +#endif From patchwork Tue Jan 14 05:11:38 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938406 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 943F82397BD for ; Tue, 14 Jan 2025 05:05:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831154; cv=none; b=SjptwnUv0CFmInTdQ5nRJ5Gq5X4Gd7bPp2DhL0de87btTF87d2GFgI/rShskeiKAdPDdM7ZRk5/HlWsH4kqGCx+7+beg2D4ZywHnPKr5f/s4jQ0GnzN1Pmgi0jfSXGwZVZq9KQkEtzJv7UBHP67pIDzlzP9hQQ0N8DUwmggW6t0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831154; c=relaxed/simple; bh=HNcOKVWgkynOsQsZmCyiwG5aufCrKz7qvDtrRc11G98=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=rsuxC+aqN7kmtI1XAHIo1kwWrpkrMdNek3YUm4g/BTfqfG2hNrXW2b/Fh4IxpDxIJbMPCmrbl9BnP98OxN9oHSLiZQ5dEHf+6RyjTvMxv+6EwDjVKcpPXu57aHWqlvf42Qwj0ONGZS9xTWK5Jpuv3MpPiCZISoKrh4LdCeLW7vE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=L0+hIFa1; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="L0+hIFa1" Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E41itx022205 for ; Tue, 14 Jan 2025 05:05:51 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= 7I2ZpH0MSoZBEKik/5sjgM3rSjLlQOF9XJbz0TLhn9A=; b=L0+hIFa1T5VtNHHe bJm3WN5qxaOHJyoTZBAMOnox7Rm8bT/18wrtNKVz3KPFDeOHj6ebgvJcfkYxU3J3 8oSzcCxMNexLPycwh9a+BZifMCARB1XkX2RKpyv62IQhOAHmZYEs/FgaTlytRMZ5 UpJQ7xICyoW1zEeiAh6v8fil33+jYq1+xAPTuwhzZmz9wUOpuHHwmKIQrUgqa+LB Qacfk1V0bTROA6gsD/cyfxt7PdEaQ37GJfYnjC0tbjNQJBDAVJuUoGosyRnc1fVH CU3tKthqaSoo8O5Y6yxx6h1+dWqbmqELl06mrU5VK2THXQkWC4xuwUC9Tq3jOOdL BAIplA== Received: from mail-oi1-f198.google.com (mail-oi1-f198.google.com [209.85.167.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445gh603at-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:50 +0000 (GMT) Received: by mail-oi1-f198.google.com with SMTP id 5614622812f47-3eee0e2a528so4077069b6e.1 for ; Mon, 13 Jan 2025 21:05:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831150; x=1737435950; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=7I2ZpH0MSoZBEKik/5sjgM3rSjLlQOF9XJbz0TLhn9A=; b=pnQ7ywgiXcPIO7cGL1psksV3lIsoXcM/3vnvzhx7eyZBHlI53ufgyQsbU0GXNcvFcJ sGw4oZhlXM8qK3AaiG2N1JrXp4uLHCEWj0ABe8uN3QJxnkehKp9hXaGQs3uY7VJgO2ho 6oQV2e7MRRVIqfLGeHpZKNpDzin3aWhU29PFr1QIkOgUuaxneacVibI0pi7IPri9/Are N2se7VJH9AmKip9w774f7qmKdWLQmPlrms5dfwoZJ5IBUKKpkrt3Y3/58eSAwB888b3M Kp2wByD37dT+mj6YNzuF+ms4GeQ+8EUVm/WJliIslFuff6UeS6Q74ASmjkYyvvvB+TiY 0VWQ== X-Gm-Message-State: AOJu0Yxolfr0qbrGOpl2dcviJf9+15I9PxTTwCDzzhJ7r+JD0ZaEFq6l tQM9iO/jwAOAHT2yBAe4W7s1bXhCqn3lmg0tG3xs4HeD3VExQnZU6CX/PVJS6zu69ktn8h63jXC /aUhV5ivymcSV2qs9mEC/67r1oUgwVgVZckbQ2Z6iZcF5GARO2/UHS+flqKduLgQK X-Gm-Gg: ASbGncvus/RQnWnAGNbxCdKyi5lJRELYXJMV+aMEPL7VJ6L+Jgqt1dwl4axAp1/F+z0 pZPZE9MzsHa6ylNsCIuGHo/E6wPBVbqL3MBTjyPdOicGZcj3xQkEqBlL4YZUZaKmN15swo5xyAz /+RNu2zuiONpBjC56j8oTdYpQdHLeG4dUZIJHstPjS8kVw7KtYUijvTJ1bsOIeAMG6mxUK10qYm gm5deVGd6sZBB6eWK8BmeTK/wkGbL5uJegWDd2jpthpPLc8uY4IkQc286pE1+OF9mgwXhgNCBnz 1phCt8YJyBA8jC7an0HPws+8ovrGaMo4t6jsXaV5+VmFFD6QuczeSDW2 X-Received: by 2002:a05:6808:2026:b0:3ea:443e:d1cd with SMTP id 5614622812f47-3ef2ed8a3dbmr3343796b6e.34.1736831149857; Mon, 13 Jan 2025 21:05:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IG+gUzO4oPE8WL+6+zT4G5culPHMuy1PnSlPkXpFnletZ4dNXodA20W8hlF7+K2WN+2sYSuvQ== X-Received: by 2002:a05:6808:2026:b0:3ea:443e:d1cd with SMTP id 5614622812f47-3ef2ed8a3dbmr3343768b6e.34.1736831149458; Mon, 13 Jan 2025 21:05:49 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:48 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:38 -0800 Subject: [PATCH v3 05/12] of: overlays: dwc3-flattening: Add Qualcomm Arm32 overlays Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-5-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=11881; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=HNcOKVWgkynOsQsZmCyiwG5aufCrKz7qvDtrRc11G98=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVp/QB6yC+BHC8j5GvacF7Nvn4ICJDkLLPX SflYtgeR+uJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcWiKw//Uhyzkd0STQcAAV7kT2fVl8Ewe5JoqcRo2br2TSJ w/xkWDpBVSi/pK2QuDnIxyjr/KtBuQZ6v7BWLUE/7k89Qc63Rsq5nTA9A8/uiy6GOWRCEeVamJW H3tOVGe6UCFBESasOjQHOkzo0S/QpQll5949WkXbkqCoM+VOPyMTOnbKXRkddZvKcdstK5MLwsz 0p9xD8bjyte+UnpmlDMWzIr3XJQEB9wC1Ys59RaJVdsQvyGFcqgKeEvYYDNYLtUXzksem94oj/O ob/JL1cZFRPa5m8vkGMJnlAXo2IhLgNZsXnklN1QuPIRVTM8qhNYXeGlFC5cP8lj/G7+LGLOVJb c8RRys3eJt9n6YCDur77w4pT4ag88GikuYXHpi4XoB0jC/ewSXdgF1i09lPrLlombwPHIl8x/BJ m2tvOTittEJsP3wTZMSB0cWWawuWxqbpO0v36nXwARevtdG2YFJsRcMCbEAWZ06+55ehf6PrNFA 5yftg+n7WpaihzfysZrdOvph6sg1Osfk2GizSIgsqRSLscZmdE+kvnM6bp9Xl5ZW/mieUtGRNKs DMLNIiv64CxwqdCgLnF+xssYWOxBar9wcununXf/j3dERIyrTMcLZ0JICUeIiTS2AgT5IUdK6UE JhaeNghARkVTq6p7B9yMrxpYcOHDu1ADcSWhwd3Jw9nE= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: -nNiwlSm2IYbZ4apQmFdrNYJI47IvIrT X-Proofpoint-GUID: -nNiwlSm2IYbZ4apQmFdrNYJI47IvIrT X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 mlxscore=0 suspectscore=0 malwarescore=0 mlxlogscore=999 phishscore=0 clxscore=1015 spamscore=0 lowpriorityscore=0 priorityscore=1501 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 Introduce the overlays necessary for migrating Qualcomm Arm32 boards currently present in the upstream Linux kernel. Signed-off-by: Bjorn Andersson --- drivers/of/overlays/dwc3-flattening/Makefile | 6 ++++ .../of/overlays/dwc3-flattening/dwc3-flattening.c | 42 ++++++++++++++++++++++ .../of/overlays/dwc3-flattening/dwc3-flattening.h | 13 +++++++ .../overlays/dwc3-flattening/dwc3-qcom_ipq4018.dts | 36 +++++++++++++++++++ .../dwc3-qcom_ipq4018_8dev_jalapeno.dts | 38 ++++++++++++++++++++ .../overlays/dwc3-flattening/dwc3-qcom_ipq4019.dts | 38 ++++++++++++++++++++ .../overlays/dwc3-flattening/dwc3-qcom_ipq8064.dts | 40 +++++++++++++++++++++ .../overlays/dwc3-flattening/dwc3-qcom_sdx55.dts | 38 ++++++++++++++++++++ .../overlays/dwc3-flattening/dwc3-qcom_sdx65.dts | 38 ++++++++++++++++++++ 9 files changed, 289 insertions(+) diff --git a/drivers/of/overlays/dwc3-flattening/Makefile b/drivers/of/overlays/dwc3-flattening/Makefile index 78ed59517887..248ddabd424e 100644 --- a/drivers/of/overlays/dwc3-flattening/Makefile +++ b/drivers/of/overlays/dwc3-flattening/Makefile @@ -2,3 +2,9 @@ obj-$(CONFIG_OF_OVERLAYS_DWC3_FLATTENING) += dwc3-flattening-overlay.o dwc3-flattening-overlay-y += dwc3-flattening.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq4018.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq4018_8dev_jalapeno.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq4019.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq8064.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdx55.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdx65.dtb.o diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c index fe8e42627fe3..0a3a31c5088b 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c @@ -21,7 +21,49 @@ struct dwc3_overlay_data { const char *migrate_match; }; +static const struct dwc3_overlay_data dwc3_qcom_ipq4018_overlay = { + .fdt = __dtb_dwc3_qcom_ipq4018_begin, + .end = __dtb_dwc3_qcom_ipq4018_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq4018_8dev_jalapeno_overlay = { + .fdt = __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_begin, + .end = __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq4019_overlay = { + .fdt = __dtb_dwc3_qcom_ipq4019_begin, + .end = __dtb_dwc3_qcom_ipq4019_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq8064_overlay = { + .fdt = __dtb_dwc3_qcom_ipq8064_begin, + .end = __dtb_dwc3_qcom_ipq8064_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdx55_overlay = { + .fdt = __dtb_dwc3_qcom_sdx55_begin, + .end = __dtb_dwc3_qcom_sdx55_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdx65_overlay = { + .fdt = __dtb_dwc3_qcom_sdx65_begin, + .end = __dtb_dwc3_qcom_sdx65_end, + .migrate_match = "qcom,dwc3", +}; + static const struct of_device_id dwc3_flatten_of_match[] = { + { .compatible = "8dev,jalapeno", .data = &dwc3_qcom_ipq4018_8dev_jalapeno_overlay }, + { .compatible = "qcom,ipq4018", .data = &dwc3_qcom_ipq4018_overlay }, + { .compatible = "qcom,ipq4019", .data = &dwc3_qcom_ipq4019_overlay }, + { .compatible = "qcom,ipq8064", .data = &dwc3_qcom_ipq8064_overlay }, + { .compatible = "qcom,sdx55", .data = &dwc3_qcom_sdx55_overlay }, + { .compatible = "qcom,sdx65", .data = &dwc3_qcom_sdx65_overlay }, {} }; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h index 6147376d3c92..57d7dbc94980 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h @@ -4,4 +4,17 @@ #include +extern u8 __dtb_dwc3_qcom_ipq4018_begin[]; +extern u8 __dtb_dwc3_qcom_ipq4018_end[]; +extern u8 __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_begin[]; +extern u8 __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_end[]; +extern u8 __dtb_dwc3_qcom_ipq4019_begin[]; +extern u8 __dtb_dwc3_qcom_ipq4019_end[]; +extern u8 __dtb_dwc3_qcom_ipq8064_begin[]; +extern u8 __dtb_dwc3_qcom_ipq8064_end[]; +extern u8 __dtb_dwc3_qcom_sdx55_begin[]; +extern u8 __dtb_dwc3_qcom_sdx55_end[]; +extern u8 __dtb_dwc3_qcom_sdx65_begin[]; +extern u8 __dtb_dwc3_qcom_sdx65_end[]; + #endif diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018.dts new file mode 100644 index 000000000000..1bd86a1852ba --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xf8100>; + phys = <&usb3_hs_phy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc/usb@60f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x06000000 0xf8100>; + phys = <&usb2_hs_phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018_8dev_jalapeno.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018_8dev_jalapeno.dts new file mode 100644 index 000000000000..bdc76b73c1fe --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4018_8dev_jalapeno.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xf8100>; + phys = <&usb3_hs_phy>, + <&usb3_ss_phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc/usb@60f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x06000000 0xf8100>; + phys = <&usb2_hs_phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4019.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4019.dts new file mode 100644 index 000000000000..bdc76b73c1fe --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq4019.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xf8100>; + phys = <&usb3_hs_phy>, + <&usb3_ss_phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc/usb@60f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq4019-dwc3", "qcom,snps-dwc3"; + reg = <0x06000000 0xf8100>; + phys = <&usb2_hs_phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8064.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8064.dts new file mode 100644 index 000000000000..8e29a17472c6 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8064.dts @@ -0,0 +1,40 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@100f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq8064-dwc3", "qcom,snps-dwc3"; + reg = <0x10000000 0x14d00>; + phys = <&hs_phy_0>, + <&ss_phy_0>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc/usb@110f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq8064-dwc3", "qcom,snps-dwc3"; + reg = <0x11000000 0x14d00>; + phys = <&hs_phy_1>, + <&ss_phy_1>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx55.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx55.dts new file mode 100644 index 000000000000..9ebb5d42f355 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx55.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@a6f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,sdx55-dwc3", "qcom,snps-dwc3"; + reg = <0x0a600000 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 51 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1a0 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx65.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx65.dts new file mode 100644 index 000000000000..239caec1f80d --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx65.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc/usb@a6f8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,sdx65-dwc3", "qcom,snps-dwc3"; + reg = <0x0a600000 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 19 IRQ_TYPE_EDGE_BOTH>, + <&pdc 18 IRQ_TYPE_EDGE_BOTH>, + <&pdc 76 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1a0 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; From patchwork Tue Jan 14 05:11:39 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938408 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0498323D3CF for ; Tue, 14 Jan 2025 05:05:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831164; cv=none; b=leIl/u3Ycl38t+7JIDYWXTvro4AdRljaVxIKTCHLQPtn747jzU0kHiAIc15e4MEKgE22BtXOrRxnnMogFiYiogOTWAH/5rfqV/IHySkc46yAAfkR6fHjaC4tbwA6txxvhlG8gRtLP2LGpb3WeCJdqclJGjqLXhfgQyN3Gtos0Dk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831164; c=relaxed/simple; bh=eVZ1RmTHKgbnk1IWLkQv54xVHndrD+zNyODhTeRc7zc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=NK9G4vrGEsRBrB2O79iKXAyP//+oGX6DCv+ZewM6qn8VFIHodbwGLbG0lxekM5gnTu7qnnc8YkOfKzoCjqdgHOKN/+XMgad9+Ln6YtJAJV0XvoG5THlZ/dDf8YyuKmfmbaXqq30hJCwZglcxKhKZw9RnuOxFOmoOiqL+wqLi010= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=eHZYB7Gl; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="eHZYB7Gl" Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DJLZ9P002893 for ; Tue, 14 Jan 2025 05:05:55 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= ZCBjS8nUjkynSvy/BD/OVnxm4MFnRm7rnyz4Vr/pees=; b=eHZYB7Glwk+E5V8E mkJ1nwlnJz80aUfH0ZOhqnp2OY1smKXahz1d7xSPL0OU63do33vxucxdR6w0VaTU 02+wlX9EBYVu/7h28Z+VQu9ZYIx4zpOtMgDEcP75QgSDoKZDa79/wWKyX0Yv1AbV fhHUjLUNd/4FsxuZ8eh/MrHkTJpgqNtYn3GmJtUSdRX7a94Fq1m/oBMT8a4nJUJN pIu9tTY0gX364O1ZhfCyzD68luCCrmGX82YeDwOq+4RXuq+xcApn4a89KDobjF7b A7woH+GQcuTvHOZkWHxOxGVc+Zyq8Qjr3Ajb5VulL5yyAaRt4LgasEHoZjV8K0xd qR/vpg== Received: from mail-oi1-f199.google.com (mail-oi1-f199.google.com [209.85.167.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4458ww92d8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:05:54 +0000 (GMT) Received: by mail-oi1-f199.google.com with SMTP id 5614622812f47-3eb81b5cbfaso3845177b6e.3 for ; Mon, 13 Jan 2025 21:05:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831153; x=1737435953; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZCBjS8nUjkynSvy/BD/OVnxm4MFnRm7rnyz4Vr/pees=; b=tcAhjNMywxaoDJVF5I9FnJPAeB9mF+3sQHkSqYsMCAu1TEnBIb+ViPkYKhyPWyz0zj u6gj0tt3Ijt9ePB8oIEahp/2s9p0W++gCwYF5W8JhSP6/qeQGpT8aq4w/wB5O0Gh6WDo FYTS3LvCSuYo/GRBwANP/GcP+QmlhYwyiqsljzYsfUB6O5Bmq3RJYpJ7GNOg5UdALH0t D/FiQc9Z0s9joAoQrubz2n3jNhp+BwfO+dlwTzgwuQG9KOFF4JajyE8HmcG1IjGkQFJ3 7inbulyAxyrWHenurgoYf8tmHvp6UVJ49Z7fmJqrfAX32f+nje1MelPHF0hJP99XBfvP oMzQ== X-Gm-Message-State: AOJu0YzBAyMaOZy5zsDFqWPzS6gG52ttOicRXHUCM1v/4D/mul9H1BQY 2ngsLH6IKF01ULCB189+PHEjcYyxuRaOkmz6ic/xAMUOPyluGxAwzf+L9vUwrAspotCrVBeZOXZ KWjkB2xPGhR/Xk7mp9kciPJCiDYMhxd/fh/G0ty/OdbLpdgbahf9osvDrVat1K52q X-Gm-Gg: ASbGncs/VF0hV0D5E2ioSiSlbKykEUGbn7ZxGDhN/WopipJW+1MYODI+PhV+fNHrMJO /jQ61rl6aWV5egLZT4FQ/FW7ZF7u9dibaKwsX5RHiqbRxh9uJB8GC57lqDTsg65UTG1sgELT6lz AZ2wWfQe3/GgOZk0xdEuPa4Zw/uHoa5GA252LkTGNXEKRdS5nM30SdxXsxnVlhW6AgDV+B7cRJB fJTJOfox6QV4sqWmDCgaqNPaqAQD/DQ+IuFXfcoEtRDbXfTxpnICm3037H5lc12Laabf4aekni1 atOvLMMpixn6vxHgyGVARxaC0FqUOVxbZKZsyoLFiFD1KH7QRMBahPoT X-Received: by 2002:a05:6808:3c89:b0:3eb:5c27:f75c with SMTP id 5614622812f47-3ef2ec96edemr14883579b6e.12.1736831152085; Mon, 13 Jan 2025 21:05:52 -0800 (PST) X-Google-Smtp-Source: AGHT+IE3gmdick5K1Gwg79wayWgfEZvhcQpgGj6YFljRD0zzdMoEYGxZ3On2Jv9CnQU0ZS1XCvdvOQ== X-Received: by 2002:a05:6808:3c89:b0:3eb:5c27:f75c with SMTP id 5614622812f47-3ef2ec96edemr14883544b6e.12.1736831151259; Mon, 13 Jan 2025 21:05:51 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:50 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:39 -0800 Subject: [PATCH v3 06/12] of: overlays: dwc3-flattening: Add Qualcomm Arm64 board overlays Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-6-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=214742; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=eVZ1RmTHKgbnk1IWLkQv54xVHndrD+zNyODhTeRc7zc=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVxXk4c5S99sHGdclgsEd3uMJt9gL9q7gAI 8c9p2Hjw/uJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcULfA/9FXfyNOveoYMJOWiVPF2SZ6dEW2h2Yeu/LLqawtu 2rloO9Ra8GQ99E3yIQ700inj7TvN8hEq/VxphcDaN6VinhK6waXYKZyYh5qCyRaQu2LslQYa5b2 EslXO8RtN/4kqiOsY4AGHUbwVZ1qVEjEFexMeZCjQ6voRhYH31t29inn1x7jEzofeXojPgrPEj+ iooyDiXmHHT2+Q2PTSHDITG1FpFnXqHDlcehCdlcD6GIrDevUJwB7zEXoVrDxt9UCtasjcKWlYi P2oSMKiQJoXoE/Ksed8xwPjqh1CxQa0PmoqqEkLzFnr5kDvlewG6Jdnh7T91ekLNUDL1GmBBlnz 1WJdm93W6nchqY2tcpyzFcu9B0OV0dmoU4rGivFMMboM6+0o1JgQra6z21CI+0f7qyldAegxbz0 NBjrh7fHdk/mBJdyISJccBvYBPOiiqpb7xoYSRdhJ1iirS2G0h0W8NDuxyHtSTC0oeQ/eEnglJG XuIhLqoVb1RBNGIVyhswg4qOUEKJISVR0+eyuZAbGt3yL/ROdzJCutLHYcxm8scRQyxlI+f+2gT OARuIlkgwyXXz1Dprt02rxxgoGhjlrrPFf/N+uLrdBYhEgnuCOzzfe9Yk1CaukeOtaCaIwO17kn lVfivvLwqGfyWVyhtKRI6O2vI6B4q0PdfXEY+RAYB+Y0= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: Ao3Rrp8VKxmX-BvqDrhSTtw0yUaMdppX X-Proofpoint-ORIG-GUID: Ao3Rrp8VKxmX-BvqDrhSTtw0yUaMdppX X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 spamscore=0 mlxlogscore=999 mlxscore=0 clxscore=1015 impostorscore=0 malwarescore=0 adultscore=0 bulkscore=0 phishscore=0 suspectscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140039 Introduce the overlays necessary for migrating Qualcomm Arm64 boards currently present in the upstream Linux kernel. Signed-off-by: Bjorn Andersson --- drivers/of/overlays/dwc3-flattening/Makefile | 84 +++ .../of/overlays/dwc3-flattening/dwc3-flattening.c | 588 +++++++++++++++++++++ .../of/overlays/dwc3-flattening/dwc3-flattening.h | 168 ++++++ .../overlays/dwc3-flattening/dwc3-qcom_apq8094.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_apq8096.dts | 60 +++ .../dwc3-qcom_apq8096_inforce_ifc6640.dts | 58 ++ .../overlays/dwc3-flattening/dwc3-qcom_ipq5018.dts | 28 + .../overlays/dwc3-flattening/dwc3-qcom_ipq5332.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_ipq5424.dts | 58 ++ .../overlays/dwc3-flattening/dwc3-qcom_ipq6018.dts | 54 ++ .../overlays/dwc3-flattening/dwc3-qcom_ipq8074.dts | 58 ++ .../overlays/dwc3-flattening/dwc3-qcom_ipq9574.dts | 29 + .../overlays/dwc3-flattening/dwc3-qcom_msm8953.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_msm8992.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_msm8994.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_msm8996.dts | 58 ++ .../dwc3-qcom_msm8996_oneplus_oneplus3.dts | 56 ++ .../dwc3-qcom_msm8996_oneplus_oneplus3t.dts | 56 ++ .../dwc3-qcom_msm8996_sony_dora_row.dts | 57 ++ .../dwc3-qcom_msm8996_sony_kagura_row.dts | 57 ++ .../dwc3-qcom_msm8996_sony_keyaki_row.dts | 57 ++ .../dwc3-qcom_msm8996_xiaomi_gemini.dts | 56 ++ .../dwc3-qcom_msm8996_xiaomi_natrium.dts | 56 ++ .../dwc3-qcom_msm8996_xiaomi_scorpio.dts | 56 ++ .../overlays/dwc3-flattening/dwc3-qcom_msm8998.dts | 34 ++ .../dwc3-qcom_msm8998_fxtec_pro1.dts | 35 ++ .../dwc3-qcom_msm8998_oneplus_cheeseburger.dts | 32 ++ .../dwc3-qcom_msm8998_oneplus_dumpling.dts | 32 ++ .../dwc3-qcom_msm8998_sony_xperia_lilac.dts | 35 ++ .../dwc3-qcom_msm8998_sony_xperia_maple.dts | 35 ++ .../dwc3-qcom_msm8998_sony_xperia_poplar.dts | 35 ++ .../dwc3-qcom_msm8998_xiaomi_sagit.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_qcm2290.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_qcm6490.dts | 63 +++ .../overlays/dwc3-flattening/dwc3-qcom_qcs404.dts | 56 ++ .../overlays/dwc3-flattening/dwc3-qcom_qcs615.dts | 62 +++ .../overlays/dwc3-flattening/dwc3-qcom_qcs8300.dts | 62 +++ .../overlays/dwc3-flattening/dwc3-qcom_qdu1000.dts | 38 ++ .../overlays/dwc3-flattening/dwc3-qcom_qru1000.dts | 38 ++ .../overlays/dwc3-flattening/dwc3-qcom_sa8155p.dts | 71 +++ .../overlays/dwc3-flattening/dwc3-qcom_sa8540p.dts | 129 +++++ .../overlays/dwc3-flattening/dwc3-qcom_sa8775p.dts | 90 ++++ .../dwc3-flattening/dwc3-qcom_sar2130p.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sc7180.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sc7280.dts | 63 +++ .../overlays/dwc3-flattening/dwc3-qcom_sc8180x.dts | 109 ++++ .../dwc3-flattening/dwc3-qcom_sc8280xp.dts | 129 +++++ .../dwc3-qcom_sc8280xp_microsoft_blackrock.dts | 121 +++++ .../overlays/dwc3-flattening/dwc3-qcom_sda660.dts | 59 +++ .../overlays/dwc3-flattening/dwc3-qcom_sdm450.dts | 33 ++ .../overlays/dwc3-flattening/dwc3-qcom_sdm630.dts | 57 ++ .../overlays/dwc3-flattening/dwc3-qcom_sdm632.dts | 32 ++ .../overlays/dwc3-flattening/dwc3-qcom_sdm636.dts | 59 +++ .../overlays/dwc3-flattening/dwc3-qcom_sdm660.dts | 57 ++ .../overlays/dwc3-flattening/dwc3-qcom_sdm670.dts | 36 ++ .../overlays/dwc3-flattening/dwc3-qcom_sdm845.dts | 64 +++ .../dwc3-qcom_sdm845_lenovo_yoga_c630.dts | 67 +++ .../dwc3-flattening/dwc3-qcom_sdm845_lg_judyln.dts | 67 +++ .../dwc3-flattening/dwc3-qcom_sdm845_lg_judyp.dts | 67 +++ .../dwc3-qcom_sdm845_qcom_sdm845_mtp.dts | 67 +++ .../dwc3-qcom_sdm845_samsung_starqltechn.dts | 67 +++ .../dwc3-qcom_sdm845_samsung_w737.dts | 67 +++ .../dwc3-qcom_sdm845_shift_axolotl.dts | 67 +++ .../dwc3-qcom_sdm845_thundercomm_db845c.dts | 67 +++ .../dwc3-qcom_sdm845_xiaomi_beryllium.dts | 67 +++ .../dwc3-qcom_sdm845_xiaomi_beryllium_ebbg.dts | 67 +++ .../overlays/dwc3-flattening/dwc3-qcom_sdx75.dts | 36 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm4250.dts | 37 ++ .../dwc3-qcom_sm4250_oneplus_billie2.dts | 35 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm6115.dts | 37 ++ .../dwc3-qcom_sm6115_lenovo_j606f.dts | 35 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm6125.dts | 36 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm6350.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm6375.dts | 36 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm7125.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm7225.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm7325.dts | 60 +++ .../overlays/dwc3-flattening/dwc3-qcom_sm8150.dts | 67 +++ .../overlays/dwc3-flattening/dwc3-qcom_sm8250.dts | 67 +++ .../dwc3-qcom_sm8250_xiaomi_elish.dts | 64 +++ .../overlays/dwc3-flattening/dwc3-qcom_sm8350.dts | 67 +++ .../dwc3-qcom_sm8350_microsoft_surface_duo2.dts | 67 +++ .../dwc3-qcom_sm8350_qcom_sm8350_hdk.dts | 69 +++ .../dwc3-qcom_sm8350_qcom_sm8350_mtp.dts | 67 +++ .../dwc3-qcom_sm8350_sony_pdx214_generic.dts | 67 +++ .../dwc3-qcom_sm8350_sony_pdx215_generic.dts | 67 +++ .../overlays/dwc3-flattening/dwc3-qcom_sm8450.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm8550.dts | 39 ++ .../overlays/dwc3-flattening/dwc3-qcom_sm8650.dts | 39 ++ .../dwc3-flattening/dwc3-qcom_x1e80100.dts | 153 ++++++ .../dwc3-qcom_x1e80100_hp_omnibook_x14.dts | 149 ++++++ 91 files changed, 5782 insertions(+) diff --git a/drivers/of/overlays/dwc3-flattening/Makefile b/drivers/of/overlays/dwc3-flattening/Makefile index 248ddabd424e..afc509d97d1b 100644 --- a/drivers/of/overlays/dwc3-flattening/Makefile +++ b/drivers/of/overlays/dwc3-flattening/Makefile @@ -2,9 +2,93 @@ obj-$(CONFIG_OF_OVERLAYS_DWC3_FLATTENING) += dwc3-flattening-overlay.o dwc3-flattening-overlay-y += dwc3-flattening.o +dwc3-flattening-overlay-y += dwc3-qcom_apq8094.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_apq8096.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_apq8096_inforce_ifc6640.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_ipq4018.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_ipq4018_8dev_jalapeno.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_ipq4019.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq5018.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq5332.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq5424.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq6018.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_ipq8064.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq8074.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_ipq9574.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8953.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8992.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8994.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_oneplus_oneplus3.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_oneplus_oneplus3t.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_sony_dora_row.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_sony_kagura_row.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_sony_keyaki_row.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_xiaomi_gemini.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_xiaomi_natrium.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8996_xiaomi_scorpio.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_fxtec_pro1.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_oneplus_cheeseburger.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_oneplus_dumpling.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_sony_xperia_lilac.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_sony_xperia_maple.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_sony_xperia_poplar.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_msm8998_xiaomi_sagit.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qcm2290.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qcm6490.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qcs404.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qcs615.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qcs8300.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qdu1000.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_qru1000.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sa8155p.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sa8540p.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sa8775p.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sar2130p.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sc7180.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sc7280.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sc8180x.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sc8280xp.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sc8280xp_microsoft_blackrock.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sda660.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm450.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm630.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm632.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm636.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm660.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm670.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_lenovo_yoga_c630.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_lg_judyln.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_lg_judyp.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_qcom_sdm845_mtp.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_samsung_starqltechn.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_samsung_w737.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_shift_axolotl.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_thundercomm_db845c.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_xiaomi_beryllium.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdm845_xiaomi_beryllium_ebbg.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_sdx55.dtb.o dwc3-flattening-overlay-y += dwc3-qcom_sdx65.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sdx75.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm4250.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm4250_oneplus_billie2.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm6115.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm6115_lenovo_j606f.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm6125.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm6350.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm6375.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm7125.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm7225.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm7325.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8150.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8250.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8250_xiaomi_elish.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8350.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8350_qcom_sm8350_hdk.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8450.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8550.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_sm8650.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_x1e80100.dtb.o +dwc3-flattening-overlay-y += dwc3-qcom_x1e80100_hp_omnibook_x14.dtb.o diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c index 0a3a31c5088b..d33cdf6661c0 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c @@ -21,6 +21,24 @@ struct dwc3_overlay_data { const char *migrate_match; }; +static const struct dwc3_overlay_data dwc3_qcom_apq8094_overlay = { + .fdt = __dtb_dwc3_qcom_apq8094_begin, + .end = __dtb_dwc3_qcom_apq8094_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_apq8096_overlay = { + .fdt = __dtb_dwc3_qcom_apq8096_begin, + .end = __dtb_dwc3_qcom_apq8096_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_apq8096_inforce_ifc6640_overlay = { + .fdt = __dtb_dwc3_qcom_apq8096_inforce_ifc6640_begin, + .end = __dtb_dwc3_qcom_apq8096_inforce_ifc6640_end, + .migrate_match = "qcom,dwc3", +}; + static const struct dwc3_overlay_data dwc3_qcom_ipq4018_overlay = { .fdt = __dtb_dwc3_qcom_ipq4018_begin, .end = __dtb_dwc3_qcom_ipq4018_end, @@ -39,12 +57,372 @@ static const struct dwc3_overlay_data dwc3_qcom_ipq4019_overlay = { .migrate_match = "qcom,dwc3", }; +static const struct dwc3_overlay_data dwc3_qcom_ipq5018_overlay = { + .fdt = __dtb_dwc3_qcom_ipq5018_begin, + .end = __dtb_dwc3_qcom_ipq5018_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq5332_overlay = { + .fdt = __dtb_dwc3_qcom_ipq5332_begin, + .end = __dtb_dwc3_qcom_ipq5332_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq5424_overlay = { + .fdt = __dtb_dwc3_qcom_ipq5424_begin, + .end = __dtb_dwc3_qcom_ipq5424_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq6018_overlay = { + .fdt = __dtb_dwc3_qcom_ipq6018_begin, + .end = __dtb_dwc3_qcom_ipq6018_end, + .migrate_match = "qcom,dwc3", +}; + static const struct dwc3_overlay_data dwc3_qcom_ipq8064_overlay = { .fdt = __dtb_dwc3_qcom_ipq8064_begin, .end = __dtb_dwc3_qcom_ipq8064_end, .migrate_match = "qcom,dwc3", }; +static const struct dwc3_overlay_data dwc3_qcom_ipq8074_overlay = { + .fdt = __dtb_dwc3_qcom_ipq8074_begin, + .end = __dtb_dwc3_qcom_ipq8074_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_ipq9574_overlay = { + .fdt = __dtb_dwc3_qcom_ipq9574_begin, + .end = __dtb_dwc3_qcom_ipq9574_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8953_overlay = { + .fdt = __dtb_dwc3_qcom_msm8953_begin, + .end = __dtb_dwc3_qcom_msm8953_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8992_overlay = { + .fdt = __dtb_dwc3_qcom_msm8992_begin, + .end = __dtb_dwc3_qcom_msm8992_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8994_overlay = { + .fdt = __dtb_dwc3_qcom_msm8994_begin, + .end = __dtb_dwc3_qcom_msm8994_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_begin, + .end = __dtb_dwc3_qcom_msm8996_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_oneplus_oneplus3_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_begin, + .end = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_oneplus_oneplus3t_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_begin, + .end = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_dora_row_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_sony_dora_row_begin, + .end = __dtb_dwc3_qcom_msm8996_sony_dora_row_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_kagura_row_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_sony_kagura_row_begin, + .end = __dtb_dwc3_qcom_msm8996_sony_kagura_row_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_keyaki_row_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_sony_keyaki_row_begin, + .end = __dtb_dwc3_qcom_msm8996_sony_keyaki_row_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_gemini_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_gemini_begin, + .end = __dtb_dwc3_qcom_msm8996_xiaomi_gemini_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_natrium_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_natrium_begin, + .end = __dtb_dwc3_qcom_msm8996_xiaomi_natrium_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_scorpio_overlay = { + .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_begin, + .end = __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_begin, + .end = __dtb_dwc3_qcom_msm8998_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_fxtec_pro1_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_fxtec_pro1_begin, + .end = __dtb_dwc3_qcom_msm8998_fxtec_pro1_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_oneplus_cheeseburger_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_begin, + .end = __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_oneplus_dumpling_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_oneplus_dumpling_begin, + .end = __dtb_dwc3_qcom_msm8998_oneplus_dumpling_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_lilac_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_begin, + .end = __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_maple_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_maple_begin, + .end = __dtb_dwc3_qcom_msm8998_sony_xperia_maple_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_poplar_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_begin, + .end = __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_msm8998_xiaomi_sagit_overlay = { + .fdt = __dtb_dwc3_qcom_msm8998_xiaomi_sagit_begin, + .end = __dtb_dwc3_qcom_msm8998_xiaomi_sagit_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qcm2290_overlay = { + .fdt = __dtb_dwc3_qcom_qcm2290_begin, + .end = __dtb_dwc3_qcom_qcm2290_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qcm6490_overlay = { + .fdt = __dtb_dwc3_qcom_qcm6490_begin, + .end = __dtb_dwc3_qcom_qcm6490_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qcs404_overlay = { + .fdt = __dtb_dwc3_qcom_qcs404_begin, + .end = __dtb_dwc3_qcom_qcs404_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qcs615_overlay = { + .fdt = __dtb_dwc3_qcom_qcs615_begin, + .end = __dtb_dwc3_qcom_qcs615_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qcs8300_overlay = { + .fdt = __dtb_dwc3_qcom_qcs8300_begin, + .end = __dtb_dwc3_qcom_qcs8300_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qdu1000_overlay = { + .fdt = __dtb_dwc3_qcom_qdu1000_begin, + .end = __dtb_dwc3_qcom_qdu1000_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_qru1000_overlay = { + .fdt = __dtb_dwc3_qcom_qru1000_begin, + .end = __dtb_dwc3_qcom_qru1000_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sa8155p_overlay = { + .fdt = __dtb_dwc3_qcom_sa8155p_begin, + .end = __dtb_dwc3_qcom_sa8155p_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sa8540p_overlay = { + .fdt = __dtb_dwc3_qcom_sa8540p_begin, + .end = __dtb_dwc3_qcom_sa8540p_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sa8775p_overlay = { + .fdt = __dtb_dwc3_qcom_sa8775p_begin, + .end = __dtb_dwc3_qcom_sa8775p_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sar2130p_overlay = { + .fdt = __dtb_dwc3_qcom_sar2130p_begin, + .end = __dtb_dwc3_qcom_sar2130p_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sc7180_overlay = { + .fdt = __dtb_dwc3_qcom_sc7180_begin, + .end = __dtb_dwc3_qcom_sc7180_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sc7280_overlay = { + .fdt = __dtb_dwc3_qcom_sc7280_begin, + .end = __dtb_dwc3_qcom_sc7280_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sc8180x_overlay = { + .fdt = __dtb_dwc3_qcom_sc8180x_begin, + .end = __dtb_dwc3_qcom_sc8180x_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sc8280xp_overlay = { + .fdt = __dtb_dwc3_qcom_sc8280xp_begin, + .end = __dtb_dwc3_qcom_sc8280xp_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sc8280xp_microsoft_blackrock_overlay = { + .fdt = __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_begin, + .end = __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sda660_overlay = { + .fdt = __dtb_dwc3_qcom_sda660_begin, + .end = __dtb_dwc3_qcom_sda660_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm450_overlay = { + .fdt = __dtb_dwc3_qcom_sdm450_begin, + .end = __dtb_dwc3_qcom_sdm450_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm630_overlay = { + .fdt = __dtb_dwc3_qcom_sdm630_begin, + .end = __dtb_dwc3_qcom_sdm630_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm632_overlay = { + .fdt = __dtb_dwc3_qcom_sdm632_begin, + .end = __dtb_dwc3_qcom_sdm632_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm636_overlay = { + .fdt = __dtb_dwc3_qcom_sdm636_begin, + .end = __dtb_dwc3_qcom_sdm636_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm660_overlay = { + .fdt = __dtb_dwc3_qcom_sdm660_begin, + .end = __dtb_dwc3_qcom_sdm660_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm670_overlay = { + .fdt = __dtb_dwc3_qcom_sdm670_begin, + .end = __dtb_dwc3_qcom_sdm670_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_begin, + .end = __dtb_dwc3_qcom_sdm845_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_lenovo_yoga_c630_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_begin, + .end = __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_lg_judyln_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_lg_judyln_begin, + .end = __dtb_dwc3_qcom_sdm845_lg_judyln_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_lg_judyp_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_lg_judyp_begin, + .end = __dtb_dwc3_qcom_sdm845_lg_judyp_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_qcom_sdm845_mtp_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_begin, + .end = __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_samsung_starqltechn_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_samsung_starqltechn_begin, + .end = __dtb_dwc3_qcom_sdm845_samsung_starqltechn_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_samsung_w737_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_samsung_w737_begin, + .end = __dtb_dwc3_qcom_sdm845_samsung_w737_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_shift_axolotl_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_shift_axolotl_begin, + .end = __dtb_dwc3_qcom_sdm845_shift_axolotl_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_thundercomm_db845c_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_thundercomm_db845c_begin, + .end = __dtb_dwc3_qcom_sdm845_thundercomm_db845c_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_xiaomi_beryllium_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_begin, + .end = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_overlay = { + .fdt = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_begin, + .end = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_end, + .migrate_match = "qcom,dwc3", +}; + static const struct dwc3_overlay_data dwc3_qcom_sdx55_overlay = { .fdt = __dtb_dwc3_qcom_sdx55_begin, .end = __dtb_dwc3_qcom_sdx55_end, @@ -57,13 +435,223 @@ static const struct dwc3_overlay_data dwc3_qcom_sdx65_overlay = { .migrate_match = "qcom,dwc3", }; +static const struct dwc3_overlay_data dwc3_qcom_sdx75_overlay = { + .fdt = __dtb_dwc3_qcom_sdx75_begin, + .end = __dtb_dwc3_qcom_sdx75_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm4250_overlay = { + .fdt = __dtb_dwc3_qcom_sm4250_begin, + .end = __dtb_dwc3_qcom_sm4250_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm4250_oneplus_billie2_overlay = { + .fdt = __dtb_dwc3_qcom_sm4250_oneplus_billie2_begin, + .end = __dtb_dwc3_qcom_sm4250_oneplus_billie2_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm6115_overlay = { + .fdt = __dtb_dwc3_qcom_sm6115_begin, + .end = __dtb_dwc3_qcom_sm6115_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm6115_lenovo_j606f_overlay = { + .fdt = __dtb_dwc3_qcom_sm6115_lenovo_j606f_begin, + .end = __dtb_dwc3_qcom_sm6115_lenovo_j606f_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm6125_overlay = { + .fdt = __dtb_dwc3_qcom_sm6125_begin, + .end = __dtb_dwc3_qcom_sm6125_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm6350_overlay = { + .fdt = __dtb_dwc3_qcom_sm6350_begin, + .end = __dtb_dwc3_qcom_sm6350_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm6375_overlay = { + .fdt = __dtb_dwc3_qcom_sm6375_begin, + .end = __dtb_dwc3_qcom_sm6375_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm7125_overlay = { + .fdt = __dtb_dwc3_qcom_sm7125_begin, + .end = __dtb_dwc3_qcom_sm7125_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm7225_overlay = { + .fdt = __dtb_dwc3_qcom_sm7225_begin, + .end = __dtb_dwc3_qcom_sm7225_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm7325_overlay = { + .fdt = __dtb_dwc3_qcom_sm7325_begin, + .end = __dtb_dwc3_qcom_sm7325_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8150_overlay = { + .fdt = __dtb_dwc3_qcom_sm8150_begin, + .end = __dtb_dwc3_qcom_sm8150_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8250_overlay = { + .fdt = __dtb_dwc3_qcom_sm8250_begin, + .end = __dtb_dwc3_qcom_sm8250_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8250_xiaomi_elish_overlay = { + .fdt = __dtb_dwc3_qcom_sm8250_xiaomi_elish_begin, + .end = __dtb_dwc3_qcom_sm8250_xiaomi_elish_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8350_overlay = { + .fdt = __dtb_dwc3_qcom_sm8350_begin, + .end = __dtb_dwc3_qcom_sm8350_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8350_qcom_sm8350_hdk_overlay = { + .fdt = __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_begin, + .end = __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8450_overlay = { + .fdt = __dtb_dwc3_qcom_sm8450_begin, + .end = __dtb_dwc3_qcom_sm8450_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8550_overlay = { + .fdt = __dtb_dwc3_qcom_sm8550_begin, + .end = __dtb_dwc3_qcom_sm8550_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_sm8650_overlay = { + .fdt = __dtb_dwc3_qcom_sm8650_begin, + .end = __dtb_dwc3_qcom_sm8650_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_x1e80100_overlay = { + .fdt = __dtb_dwc3_qcom_x1e80100_begin, + .end = __dtb_dwc3_qcom_x1e80100_end, + .migrate_match = "qcom,dwc3", +}; + +static const struct dwc3_overlay_data dwc3_qcom_x1e80100_hp_omnibook_x14_overlay = { + .fdt = __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_begin, + .end = __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_end, + .migrate_match = "qcom,dwc3", +}; + static const struct of_device_id dwc3_flatten_of_match[] = { { .compatible = "8dev,jalapeno", .data = &dwc3_qcom_ipq4018_8dev_jalapeno_overlay }, + { .compatible = "fxtec,pro1", .data = &dwc3_qcom_msm8998_fxtec_pro1_overlay }, + { .compatible = "hp,omnibook-x14", .data = &dwc3_qcom_x1e80100_hp_omnibook_x14_overlay }, + { .compatible = "inforce,ifc6640", .data = &dwc3_qcom_apq8096_inforce_ifc6640_overlay }, + { .compatible = "lenovo,j606f", .data = &dwc3_qcom_sm6115_lenovo_j606f_overlay }, + { .compatible = "lenovo,yoga-c630", .data = &dwc3_qcom_sdm845_lenovo_yoga_c630_overlay }, + { .compatible = "lg,judyln", .data = &dwc3_qcom_sdm845_lg_judyln_overlay }, + { .compatible = "lg,judyp", .data = &dwc3_qcom_sdm845_lg_judyp_overlay }, + { .compatible = "microsoft,blackrock", .data = &dwc3_qcom_sc8280xp_microsoft_blackrock_overlay }, + { .compatible = "oneplus,billie2", .data = &dwc3_qcom_sm4250_oneplus_billie2_overlay }, + { .compatible = "oneplus,cheeseburger", .data = &dwc3_qcom_msm8998_oneplus_cheeseburger_overlay }, + { .compatible = "oneplus,dumpling", .data = &dwc3_qcom_msm8998_oneplus_dumpling_overlay }, + { .compatible = "oneplus,oneplus3", .data = &dwc3_qcom_msm8996_oneplus_oneplus3_overlay }, + { .compatible = "oneplus,oneplus3t", .data = &dwc3_qcom_msm8996_oneplus_oneplus3t_overlay }, + { .compatible = "qcom,apq8094", .data = &dwc3_qcom_apq8094_overlay }, + { .compatible = "qcom,apq8096", .data = &dwc3_qcom_apq8096_overlay }, { .compatible = "qcom,ipq4018", .data = &dwc3_qcom_ipq4018_overlay }, { .compatible = "qcom,ipq4019", .data = &dwc3_qcom_ipq4019_overlay }, + { .compatible = "qcom,ipq5018", .data = &dwc3_qcom_ipq5018_overlay }, + { .compatible = "qcom,ipq5332", .data = &dwc3_qcom_ipq5332_overlay }, + { .compatible = "qcom,ipq5424", .data = &dwc3_qcom_ipq5424_overlay }, + { .compatible = "qcom,ipq6018", .data = &dwc3_qcom_ipq6018_overlay }, { .compatible = "qcom,ipq8064", .data = &dwc3_qcom_ipq8064_overlay }, + { .compatible = "qcom,ipq8074", .data = &dwc3_qcom_ipq8074_overlay }, + { .compatible = "qcom,ipq9574", .data = &dwc3_qcom_ipq9574_overlay }, + { .compatible = "qcom,msm8953", .data = &dwc3_qcom_msm8953_overlay }, + { .compatible = "qcom,msm8992", .data = &dwc3_qcom_msm8992_overlay }, + { .compatible = "qcom,msm8994", .data = &dwc3_qcom_msm8994_overlay }, + { .compatible = "qcom,msm8996", .data = &dwc3_qcom_msm8996_overlay }, + { .compatible = "qcom,msm8998", .data = &dwc3_qcom_msm8998_overlay }, + { .compatible = "qcom,qcm2290", .data = &dwc3_qcom_qcm2290_overlay }, + { .compatible = "qcom,qcm6490", .data = &dwc3_qcom_qcm6490_overlay }, + { .compatible = "qcom,qcs404", .data = &dwc3_qcom_qcs404_overlay }, + { .compatible = "qcom,qcs615", .data = &dwc3_qcom_qcs615_overlay }, + { .compatible = "qcom,qcs8300", .data = &dwc3_qcom_qcs8300_overlay }, + { .compatible = "qcom,qdu1000", .data = &dwc3_qcom_qdu1000_overlay }, + { .compatible = "qcom,qru1000", .data = &dwc3_qcom_qru1000_overlay }, + { .compatible = "qcom,sa8155p", .data = &dwc3_qcom_sa8155p_overlay }, + { .compatible = "qcom,sa8540p", .data = &dwc3_qcom_sa8540p_overlay }, + { .compatible = "qcom,sa8775p", .data = &dwc3_qcom_sa8775p_overlay }, + { .compatible = "qcom,sar2130p", .data = &dwc3_qcom_sar2130p_overlay }, + { .compatible = "qcom,sc7180", .data = &dwc3_qcom_sc7180_overlay }, + { .compatible = "qcom,sc7280", .data = &dwc3_qcom_sc7280_overlay }, + { .compatible = "qcom,sc8180x", .data = &dwc3_qcom_sc8180x_overlay }, + { .compatible = "qcom,sc8280xp", .data = &dwc3_qcom_sc8280xp_overlay }, + { .compatible = "qcom,sda660", .data = &dwc3_qcom_sda660_overlay }, + { .compatible = "qcom,sdm450", .data = &dwc3_qcom_sdm450_overlay }, + { .compatible = "qcom,sdm630", .data = &dwc3_qcom_sdm630_overlay }, + { .compatible = "qcom,sdm632", .data = &dwc3_qcom_sdm632_overlay }, + { .compatible = "qcom,sdm636", .data = &dwc3_qcom_sdm636_overlay }, + { .compatible = "qcom,sdm660", .data = &dwc3_qcom_sdm660_overlay }, + { .compatible = "qcom,sdm670", .data = &dwc3_qcom_sdm670_overlay }, + { .compatible = "qcom,sdm845", .data = &dwc3_qcom_sdm845_overlay }, + { .compatible = "qcom,sdm845-mtp", .data = &dwc3_qcom_sdm845_qcom_sdm845_mtp_overlay }, { .compatible = "qcom,sdx55", .data = &dwc3_qcom_sdx55_overlay }, { .compatible = "qcom,sdx65", .data = &dwc3_qcom_sdx65_overlay }, + { .compatible = "qcom,sdx75", .data = &dwc3_qcom_sdx75_overlay }, + { .compatible = "qcom,sm4250", .data = &dwc3_qcom_sm4250_overlay }, + { .compatible = "qcom,sm6115", .data = &dwc3_qcom_sm6115_overlay }, + { .compatible = "qcom,sm6125", .data = &dwc3_qcom_sm6125_overlay }, + { .compatible = "qcom,sm6350", .data = &dwc3_qcom_sm6350_overlay }, + { .compatible = "qcom,sm6375", .data = &dwc3_qcom_sm6375_overlay }, + { .compatible = "qcom,sm7125", .data = &dwc3_qcom_sm7125_overlay }, + { .compatible = "qcom,sm7225", .data = &dwc3_qcom_sm7225_overlay }, + { .compatible = "qcom,sm7325", .data = &dwc3_qcom_sm7325_overlay }, + { .compatible = "qcom,sm8150", .data = &dwc3_qcom_sm8150_overlay }, + { .compatible = "qcom,sm8250", .data = &dwc3_qcom_sm8250_overlay }, + { .compatible = "qcom,sm8350", .data = &dwc3_qcom_sm8350_overlay }, + { .compatible = "qcom,sm8350-hdk", .data = &dwc3_qcom_sm8350_qcom_sm8350_hdk_overlay }, + { .compatible = "qcom,sm8450", .data = &dwc3_qcom_sm8450_overlay }, + { .compatible = "qcom,sm8550", .data = &dwc3_qcom_sm8550_overlay }, + { .compatible = "qcom,sm8650", .data = &dwc3_qcom_sm8650_overlay }, + { .compatible = "qcom,x1e80100", .data = &dwc3_qcom_x1e80100_overlay }, + { .compatible = "samsung,starqltechn", .data = &dwc3_qcom_sdm845_samsung_starqltechn_overlay }, + { .compatible = "samsung,w737", .data = &dwc3_qcom_sdm845_samsung_w737_overlay }, + { .compatible = "shift,axolotl", .data = &dwc3_qcom_sdm845_shift_axolotl_overlay }, + { .compatible = "sony,dora-row", .data = &dwc3_qcom_msm8996_sony_dora_row_overlay }, + { .compatible = "sony,kagura-row", .data = &dwc3_qcom_msm8996_sony_kagura_row_overlay }, + { .compatible = "sony,keyaki-row", .data = &dwc3_qcom_msm8996_sony_keyaki_row_overlay }, + { .compatible = "sony,xperia-lilac", .data = &dwc3_qcom_msm8998_sony_xperia_lilac_overlay }, + { .compatible = "sony,xperia-maple", .data = &dwc3_qcom_msm8998_sony_xperia_maple_overlay }, + { .compatible = "sony,xperia-poplar", .data = &dwc3_qcom_msm8998_sony_xperia_poplar_overlay }, + { .compatible = "thundercomm,db845c", .data = &dwc3_qcom_sdm845_thundercomm_db845c_overlay }, + { .compatible = "xiaomi,beryllium", .data = &dwc3_qcom_sdm845_xiaomi_beryllium_overlay }, + { .compatible = "xiaomi,beryllium-ebbg", .data = &dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_overlay }, + { .compatible = "xiaomi,elish", .data = &dwc3_qcom_sm8250_xiaomi_elish_overlay }, + { .compatible = "xiaomi,gemini", .data = &dwc3_qcom_msm8996_xiaomi_gemini_overlay }, + { .compatible = "xiaomi,natrium", .data = &dwc3_qcom_msm8996_xiaomi_natrium_overlay }, + { .compatible = "xiaomi,sagit", .data = &dwc3_qcom_msm8998_xiaomi_sagit_overlay }, + { .compatible = "xiaomi,scorpio", .data = &dwc3_qcom_msm8996_xiaomi_scorpio_overlay }, {} }; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h index 57d7dbc94980..bc897db4dd1e 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.h @@ -4,17 +4,185 @@ #include +extern u8 __dtb_dwc3_qcom_apq8094_begin[]; +extern u8 __dtb_dwc3_qcom_apq8094_end[]; +extern u8 __dtb_dwc3_qcom_apq8096_begin[]; +extern u8 __dtb_dwc3_qcom_apq8096_end[]; +extern u8 __dtb_dwc3_qcom_apq8096_inforce_ifc6640_begin[]; +extern u8 __dtb_dwc3_qcom_apq8096_inforce_ifc6640_end[]; extern u8 __dtb_dwc3_qcom_ipq4018_begin[]; extern u8 __dtb_dwc3_qcom_ipq4018_end[]; extern u8 __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_begin[]; extern u8 __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_end[]; extern u8 __dtb_dwc3_qcom_ipq4019_begin[]; extern u8 __dtb_dwc3_qcom_ipq4019_end[]; +extern u8 __dtb_dwc3_qcom_ipq5018_begin[]; +extern u8 __dtb_dwc3_qcom_ipq5018_end[]; +extern u8 __dtb_dwc3_qcom_ipq5332_begin[]; +extern u8 __dtb_dwc3_qcom_ipq5332_end[]; +extern u8 __dtb_dwc3_qcom_ipq5424_begin[]; +extern u8 __dtb_dwc3_qcom_ipq5424_end[]; +extern u8 __dtb_dwc3_qcom_ipq6018_begin[]; +extern u8 __dtb_dwc3_qcom_ipq6018_end[]; extern u8 __dtb_dwc3_qcom_ipq8064_begin[]; extern u8 __dtb_dwc3_qcom_ipq8064_end[]; +extern u8 __dtb_dwc3_qcom_ipq8074_begin[]; +extern u8 __dtb_dwc3_qcom_ipq8074_end[]; +extern u8 __dtb_dwc3_qcom_ipq9574_begin[]; +extern u8 __dtb_dwc3_qcom_ipq9574_end[]; +extern u8 __dtb_dwc3_qcom_msm8953_begin[]; +extern u8 __dtb_dwc3_qcom_msm8953_end[]; +extern u8 __dtb_dwc3_qcom_msm8992_begin[]; +extern u8 __dtb_dwc3_qcom_msm8992_end[]; +extern u8 __dtb_dwc3_qcom_msm8994_begin[]; +extern u8 __dtb_dwc3_qcom_msm8994_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_dora_row_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_dora_row_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_kagura_row_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_kagura_row_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_keyaki_row_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_sony_keyaki_row_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_gemini_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_gemini_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_natrium_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_natrium_end[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_begin[]; +extern u8 __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_fxtec_pro1_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_fxtec_pro1_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_oneplus_dumpling_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_oneplus_dumpling_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_maple_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_maple_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_end[]; +extern u8 __dtb_dwc3_qcom_msm8998_xiaomi_sagit_begin[]; +extern u8 __dtb_dwc3_qcom_msm8998_xiaomi_sagit_end[]; +extern u8 __dtb_dwc3_qcom_qcm2290_begin[]; +extern u8 __dtb_dwc3_qcom_qcm2290_end[]; +extern u8 __dtb_dwc3_qcom_qcm6490_begin[]; +extern u8 __dtb_dwc3_qcom_qcm6490_end[]; +extern u8 __dtb_dwc3_qcom_qcs404_begin[]; +extern u8 __dtb_dwc3_qcom_qcs404_end[]; +extern u8 __dtb_dwc3_qcom_qcs615_begin[]; +extern u8 __dtb_dwc3_qcom_qcs615_end[]; +extern u8 __dtb_dwc3_qcom_qcs8300_begin[]; +extern u8 __dtb_dwc3_qcom_qcs8300_end[]; +extern u8 __dtb_dwc3_qcom_qdu1000_begin[]; +extern u8 __dtb_dwc3_qcom_qdu1000_end[]; +extern u8 __dtb_dwc3_qcom_qru1000_begin[]; +extern u8 __dtb_dwc3_qcom_qru1000_end[]; +extern u8 __dtb_dwc3_qcom_sa8155p_begin[]; +extern u8 __dtb_dwc3_qcom_sa8155p_end[]; +extern u8 __dtb_dwc3_qcom_sa8540p_begin[]; +extern u8 __dtb_dwc3_qcom_sa8540p_end[]; +extern u8 __dtb_dwc3_qcom_sa8775p_begin[]; +extern u8 __dtb_dwc3_qcom_sa8775p_end[]; +extern u8 __dtb_dwc3_qcom_sar2130p_begin[]; +extern u8 __dtb_dwc3_qcom_sar2130p_end[]; +extern u8 __dtb_dwc3_qcom_sc7180_begin[]; +extern u8 __dtb_dwc3_qcom_sc7180_end[]; +extern u8 __dtb_dwc3_qcom_sc7280_begin[]; +extern u8 __dtb_dwc3_qcom_sc7280_end[]; +extern u8 __dtb_dwc3_qcom_sc8180x_begin[]; +extern u8 __dtb_dwc3_qcom_sc8180x_end[]; +extern u8 __dtb_dwc3_qcom_sc8280xp_begin[]; +extern u8 __dtb_dwc3_qcom_sc8280xp_end[]; +extern u8 __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_begin[]; +extern u8 __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_end[]; +extern u8 __dtb_dwc3_qcom_sda660_begin[]; +extern u8 __dtb_dwc3_qcom_sda660_end[]; +extern u8 __dtb_dwc3_qcom_sdm450_begin[]; +extern u8 __dtb_dwc3_qcom_sdm450_end[]; +extern u8 __dtb_dwc3_qcom_sdm630_begin[]; +extern u8 __dtb_dwc3_qcom_sdm630_end[]; +extern u8 __dtb_dwc3_qcom_sdm632_begin[]; +extern u8 __dtb_dwc3_qcom_sdm632_end[]; +extern u8 __dtb_dwc3_qcom_sdm636_begin[]; +extern u8 __dtb_dwc3_qcom_sdm636_end[]; +extern u8 __dtb_dwc3_qcom_sdm660_begin[]; +extern u8 __dtb_dwc3_qcom_sdm660_end[]; +extern u8 __dtb_dwc3_qcom_sdm670_begin[]; +extern u8 __dtb_dwc3_qcom_sdm670_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_lg_judyln_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_lg_judyln_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_lg_judyp_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_lg_judyp_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_samsung_starqltechn_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_samsung_starqltechn_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_samsung_w737_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_samsung_w737_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_shift_axolotl_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_shift_axolotl_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_thundercomm_db845c_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_thundercomm_db845c_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_end[]; +extern u8 __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_begin[]; +extern u8 __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_end[]; extern u8 __dtb_dwc3_qcom_sdx55_begin[]; extern u8 __dtb_dwc3_qcom_sdx55_end[]; extern u8 __dtb_dwc3_qcom_sdx65_begin[]; extern u8 __dtb_dwc3_qcom_sdx65_end[]; +extern u8 __dtb_dwc3_qcom_sdx75_begin[]; +extern u8 __dtb_dwc3_qcom_sdx75_end[]; +extern u8 __dtb_dwc3_qcom_sm4250_begin[]; +extern u8 __dtb_dwc3_qcom_sm4250_end[]; +extern u8 __dtb_dwc3_qcom_sm4250_oneplus_billie2_begin[]; +extern u8 __dtb_dwc3_qcom_sm4250_oneplus_billie2_end[]; +extern u8 __dtb_dwc3_qcom_sm6115_begin[]; +extern u8 __dtb_dwc3_qcom_sm6115_end[]; +extern u8 __dtb_dwc3_qcom_sm6115_lenovo_j606f_begin[]; +extern u8 __dtb_dwc3_qcom_sm6115_lenovo_j606f_end[]; +extern u8 __dtb_dwc3_qcom_sm6125_begin[]; +extern u8 __dtb_dwc3_qcom_sm6125_end[]; +extern u8 __dtb_dwc3_qcom_sm6350_begin[]; +extern u8 __dtb_dwc3_qcom_sm6350_end[]; +extern u8 __dtb_dwc3_qcom_sm6375_begin[]; +extern u8 __dtb_dwc3_qcom_sm6375_end[]; +extern u8 __dtb_dwc3_qcom_sm7125_begin[]; +extern u8 __dtb_dwc3_qcom_sm7125_end[]; +extern u8 __dtb_dwc3_qcom_sm7225_begin[]; +extern u8 __dtb_dwc3_qcom_sm7225_end[]; +extern u8 __dtb_dwc3_qcom_sm7325_begin[]; +extern u8 __dtb_dwc3_qcom_sm7325_end[]; +extern u8 __dtb_dwc3_qcom_sm8150_begin[]; +extern u8 __dtb_dwc3_qcom_sm8150_end[]; +extern u8 __dtb_dwc3_qcom_sm8250_begin[]; +extern u8 __dtb_dwc3_qcom_sm8250_end[]; +extern u8 __dtb_dwc3_qcom_sm8250_xiaomi_elish_begin[]; +extern u8 __dtb_dwc3_qcom_sm8250_xiaomi_elish_end[]; +extern u8 __dtb_dwc3_qcom_sm8350_begin[]; +extern u8 __dtb_dwc3_qcom_sm8350_end[]; +extern u8 __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_begin[]; +extern u8 __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_end[]; +extern u8 __dtb_dwc3_qcom_sm8450_begin[]; +extern u8 __dtb_dwc3_qcom_sm8450_end[]; +extern u8 __dtb_dwc3_qcom_sm8550_begin[]; +extern u8 __dtb_dwc3_qcom_sm8550_end[]; +extern u8 __dtb_dwc3_qcom_sm8650_begin[]; +extern u8 __dtb_dwc3_qcom_sm8650_end[]; +extern u8 __dtb_dwc3_qcom_x1e80100_begin[]; +extern u8 __dtb_dwc3_qcom_x1e80100_end[]; +extern u8 __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_begin[]; +extern u8 __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_end[]; #endif diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8094.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8094.dts new file mode 100644 index 000000000000..8ca699460ec3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8094.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@f92f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8994-dwc3", "qcom,snps-dwc3"; + reg = <0xf9200000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096.dts new file mode 100644 index 000000000000..f05d6c905e85 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096.dts @@ -0,0 +1,60 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&usb2_id>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + extcon = <&usb3_id>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096_inforce_ifc6640.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096_inforce_ifc6640.dts new file mode 100644 index 000000000000..1b9ae360f1ce --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_apq8096_inforce_ifc6640.dts @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5018.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5018.dts new file mode 100644 index 000000000000..44266816a50b --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5018.dts @@ -0,0 +1,28 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq5018-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xe400>; + interrupts = , + ; + interrupt-names = "dwc_usb3", + "hs_phy_irq"; + phys = <&usbphy0>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5332.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5332.dts new file mode 100644 index 000000000000..6e6699e4f859 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5332.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq5332-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xe400>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + phys = <&usbphy0>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5424.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5424.dts new file mode 100644 index 000000000000..e14dc85d8b39 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq5424.dts @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb2@1e00000"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,ipq5424-dwc3", "qcom,snps-dwc3"; + reg = <0 0x01e00000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 396 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 395 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 397 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 387 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 388 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "dm_hs_phy_irq", + "dp_hs_phy_irq"; + phys = <&qusb_phy_1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb3@8a00000"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,ipq5424-dwc3", "qcom,snps-dwc3"; + reg = <0 0x08a00000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 409 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 412 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 414 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 423 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 424 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "dm_hs_phy_irq", + "dp_hs_phy_irq"; + phys = <&qusb_phy_0>, + <&ssphy_0>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq6018.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq6018.dts new file mode 100644 index 000000000000..14e7fa720831 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq6018.dts @@ -0,0 +1,54 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@70f8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq6018-dwc3", "qcom,snps-dwc3"; + reg = <0 0x07000000 0 0xd100>; + interrupts = , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy"; + phys = <&qusb_phy_1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@8af8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq6018-dwc3", "qcom,snps-dwc3"; + reg = <0 0x08a00000 0 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb_phy_0>, + <&ssphy_0>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8074.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8074.dts new file mode 100644 index 000000000000..169da32fcd24 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq8074.dts @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq8074-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb_phy_0>, + <&ssphy_0>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@8cf8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,ipq8074-dwc3", "qcom,snps-dwc3"; + reg = <0x08c00000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb_phy_1>, + <&ssphy_1>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq9574.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq9574.dts new file mode 100644 index 000000000000..ba644dde4845 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_ipq9574.dts @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8af8800"; + #address-cells = <1>; + #size-cells = <1>; + + __overlay__ { + compatible = "qcom,ipq9574-dwc3", "qcom,snps-dwc3"; + reg = <0x08a00000 0xd100>; + interrupts-extended = <&intc GIC_SPI 140 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 134 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event"; + phys = <&usb_0_qusbphy>, + <&usb_0_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8953.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8953.dts new file mode 100644 index 000000000000..2c2d8e00ab78 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8953.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@70f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8953-dwc3", "qcom,snps-dwc3"; + reg = <0x07000000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&hsusb_phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8992.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8992.dts new file mode 100644 index 000000000000..8ca699460ec3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8992.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@f92f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8994-dwc3", "qcom,snps-dwc3"; + reg = <0xf9200000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8994.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8994.dts new file mode 100644 index 000000000000..8ca699460ec3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8994.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@f92f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8994-dwc3", "qcom,snps-dwc3"; + reg = <0xf9200000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996.dts new file mode 100644 index 000000000000..1b9ae360f1ce --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996.dts @@ -0,0 +1,58 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3.dts new file mode 100644 index 000000000000..7a583de320cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3t.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3t.dts new file mode 100644 index 000000000000..7a583de320cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_oneplus_oneplus3t.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_dora_row.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_dora_row.dts new file mode 100644 index 000000000000..da6e357b0cbc --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_dora_row.dts @@ -0,0 +1,57 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + extcon = <&usb3_id>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_kagura_row.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_kagura_row.dts new file mode 100644 index 000000000000..da6e357b0cbc --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_kagura_row.dts @@ -0,0 +1,57 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + extcon = <&usb3_id>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_keyaki_row.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_keyaki_row.dts new file mode 100644 index 000000000000..da6e357b0cbc --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_sony_keyaki_row.dts @@ -0,0 +1,57 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + extcon = <&usb3_id>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_gemini.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_gemini.dts new file mode 100644 index 000000000000..7a583de320cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_gemini.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_natrium.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_natrium.dts new file mode 100644 index 000000000000..7a583de320cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_natrium.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_scorpio.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_scorpio.dts new file mode 100644 index 000000000000..7a583de320cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8996_xiaomi_scorpio.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@6af8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x06a00000 0xd000>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@76f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8996-dwc3", "qcom,snps-dwc3"; + reg = <0x07600000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&hsusb_phy2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998.dts new file mode 100644 index 000000000000..75824abf794b --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998.dts @@ -0,0 +1,34 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_fxtec_pro1.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_fxtec_pro1.dts new file mode 100644 index 000000000000..4f3aded0142d --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_fxtec_pro1.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_cheeseburger.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_cheeseburger.dts new file mode 100644 index 000000000000..3b331d0e5283 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_cheeseburger.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_dumpling.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_dumpling.dts new file mode 100644 index 000000000000..3b331d0e5283 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_oneplus_dumpling.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_lilac.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_lilac.dts new file mode 100644 index 000000000000..4f3aded0142d --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_lilac.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_maple.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_maple.dts new file mode 100644 index 000000000000..4f3aded0142d --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_maple.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_poplar.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_poplar.dts new file mode 100644 index 000000000000..4f3aded0142d --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_sony_xperia_poplar.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>, + <&usb3phy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_xiaomi_sagit.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_xiaomi_sagit.dts new file mode 100644 index 000000000000..3b331d0e5283 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_msm8998_xiaomi_sagit.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8998-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&qusb2phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm2290.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm2290.dts new file mode 100644 index 000000000000..4a43b3f1a51e --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm2290.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qcm2290-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 255 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 260 IRQ_TYPE_LEVEL_HIGH>, + <&mpm 12 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x120 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm6490.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm6490.dts new file mode 100644 index 000000000000..c9c921d55e3f --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcm6490.dts @@ -0,0 +1,63 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8cf8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x08c00000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 242 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 241 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0xa0 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xe0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs404.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs404.dts new file mode 100644 index 000000000000..794bac913137 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs404.dts @@ -0,0 +1,56 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@7678800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,qcs404-dwc3", "qcom,snps-dwc3"; + reg = <0x07580000 0xd100>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "qusb2_phy"; + phys = <&usb2_phy_prim>, + <&usb3_phy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@79b8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,qcs404-dwc3", "qcom,snps-dwc3"; + reg = <0x078c0000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "qusb2_phy"; + phys = <&usb2_phy_sec>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs615.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs615.dts new file mode 100644 index 000000000000..52f94ce9c327 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs615.dts @@ -0,0 +1,62 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qcs615-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x140 0x0>; + phys = <&usb_1_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qcs615-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 664 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 663 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 662 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0xe0 0x0>; + phys = <&usb_hsphy_2>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs8300.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs8300.dts new file mode 100644 index 000000000000..fa843e3ca9ff --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qcs8300.dts @@ -0,0 +1,62 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qcs8300-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 292 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 287 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 261 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 12 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x80 0x0>; + phys = <&usb_1_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qcs8300-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 442 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 444 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 443 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qdu1000.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qdu1000.dts new file mode 100644 index 000000000000..8d245859fae1 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qdu1000.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qdu1000-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xc0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qru1000.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qru1000.dts new file mode 100644 index 000000000000..8d245859fae1 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_qru1000.dts @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,qdu1000-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xc0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8155p.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8155p.dts new file mode 100644 index 000000000000..408d42c1649c --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8155p.dts @@ -0,0 +1,71 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8150-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x140 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + pinctrl-names = "default"; + pinctrl-0 = <&usb2phy_ac_en1_default>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8150-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x160 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + pinctrl-names = "default"; + pinctrl-0 = <&usb2phy_ac_en2_default>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8540p.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8540p.dts new file mode 100644 index 000000000000..553e8ddb91ce --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8540p.dts @@ -0,0 +1,129 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 857 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 856 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 860 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 859 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 127 IRQ_TYPE_EDGE_BOTH>, + <&pdc 126 IRQ_TYPE_EDGE_BOTH>, + <&pdc 129 IRQ_TYPE_EDGE_BOTH>, + <&pdc 128 IRQ_TYPE_EDGE_BOTH>, + <&pdc 131 IRQ_TYPE_EDGE_BOTH>, + <&pdc 130 IRQ_TYPE_EDGE_BOTH>, + <&pdc 133 IRQ_TYPE_EDGE_BOTH>, + <&pdc 132 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event_1", + "pwr_event_2", + "pwr_event_3", + "pwr_event_4", + "hs_phy_1", + "hs_phy_2", + "hs_phy_3", + "hs_phy_4", + "dp_hs_phy_1", + "dm_hs_phy_1", + "dp_hs_phy_2", + "dm_hs_phy_2", + "dp_hs_phy_3", + "dm_hs_phy_3", + "dp_hs_phy_4", + "dm_hs_phy_4", + "ss_phy_1", + "ss_phy_2"; + iommus = <&apps_smmu 0x800 0x0>; + phys = <&usb_2_hsphy0>, + <&usb_2_qmpphy0>, + <&usb_2_hsphy1>, + <&usb_2_qmpphy1>, + <&usb_2_hsphy2>, + <&usb_2_hsphy3>; + phy-names = "usb2-0", + "usb3-0", + "usb2-1", + "usb3-1", + "usb2-2", + "usb2-3"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 803 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 804 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 805 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 138 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x820 0x0>; + phys = <&usb_0_hsphy>, + <&usb_0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 810 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 811 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 790 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 136 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x860 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8775p.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8775p.dts new file mode 100644 index 000000000000..4f218dbbef8b --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sa8775p.dts @@ -0,0 +1,90 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sa8775p-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 292 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 287 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 261 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 12 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x80 0x0>; + phys = <&usb_0_hsphy>, + <&usb_0_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sa8775p-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 349 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 352 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 351 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 7 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xa0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sa8775p-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 442 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 444 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 443 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sar2130p.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sar2130p.dts new file mode 100644 index 000000000000..582bcf1b13da --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sar2130p.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sar2130p-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 347 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 350 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 349 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_1_hsphy>, + <&usb_dp_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7180.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7180.dts new file mode 100644 index 000000000000..cd4caa173891 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7180.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7180-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x540 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7280.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7280.dts new file mode 100644 index 000000000000..c9c921d55e3f --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc7280.dts @@ -0,0 +1,63 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8cf8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x08c00000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 242 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 241 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0xa0 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xe0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8180x.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8180x.dts new file mode 100644 index 000000000000..e875fb9a39aa --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8180x.dts @@ -0,0 +1,109 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8180x-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 654 IRQ_TYPE_LEVEL_HIGH>, + <&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 = "dwc_usb3", + "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"; + iommus = <&apps_smmu 0x60 0x0>; + phys = <&usb_mp_hsphy0>, + <&usb_mp_qmpphy0>, + <&usb_mp_hsphy1>, + <&usb_mp_qmpphy1>; + phy-names = "usb2-0", + "usb3-0", + "usb2-1", + "usb3-1"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8180x-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x140 0x0>; + phys = <&usb_prim_hsphy>, + <&usb_prim_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8180x-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 40 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x160 0x0>; + phys = <&usb_sec_hsphy>, + <&usb_sec_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp.dts new file mode 100644 index 000000000000..553e8ddb91ce --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp.dts @@ -0,0 +1,129 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 857 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 856 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 860 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 859 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 127 IRQ_TYPE_EDGE_BOTH>, + <&pdc 126 IRQ_TYPE_EDGE_BOTH>, + <&pdc 129 IRQ_TYPE_EDGE_BOTH>, + <&pdc 128 IRQ_TYPE_EDGE_BOTH>, + <&pdc 131 IRQ_TYPE_EDGE_BOTH>, + <&pdc 130 IRQ_TYPE_EDGE_BOTH>, + <&pdc 133 IRQ_TYPE_EDGE_BOTH>, + <&pdc 132 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event_1", + "pwr_event_2", + "pwr_event_3", + "pwr_event_4", + "hs_phy_1", + "hs_phy_2", + "hs_phy_3", + "hs_phy_4", + "dp_hs_phy_1", + "dm_hs_phy_1", + "dp_hs_phy_2", + "dm_hs_phy_2", + "dp_hs_phy_3", + "dm_hs_phy_3", + "dp_hs_phy_4", + "dm_hs_phy_4", + "ss_phy_1", + "ss_phy_2"; + iommus = <&apps_smmu 0x800 0x0>; + phys = <&usb_2_hsphy0>, + <&usb_2_qmpphy0>, + <&usb_2_hsphy1>, + <&usb_2_qmpphy1>, + <&usb_2_hsphy2>, + <&usb_2_hsphy3>; + phy-names = "usb2-0", + "usb3-0", + "usb2-1", + "usb3-1", + "usb2-2", + "usb2-3"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 803 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 804 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 805 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 138 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x820 0x0>; + phys = <&usb_0_hsphy>, + <&usb_0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 810 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 811 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 790 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 136 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x860 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp_microsoft_blackrock.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp_microsoft_blackrock.dts new file mode 100644 index 000000000000..ce33abdccccf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sc8280xp_microsoft_blackrock.dts @@ -0,0 +1,121 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 857 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 856 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 860 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 859 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 127 IRQ_TYPE_EDGE_BOTH>, + <&pdc 126 IRQ_TYPE_EDGE_BOTH>, + <&pdc 129 IRQ_TYPE_EDGE_BOTH>, + <&pdc 128 IRQ_TYPE_EDGE_BOTH>, + <&pdc 131 IRQ_TYPE_EDGE_BOTH>, + <&pdc 130 IRQ_TYPE_EDGE_BOTH>, + <&pdc 133 IRQ_TYPE_EDGE_BOTH>, + <&pdc 132 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event_1", + "pwr_event_2", + "pwr_event_3", + "pwr_event_4", + "hs_phy_1", + "hs_phy_2", + "hs_phy_3", + "hs_phy_4", + "dp_hs_phy_1", + "dm_hs_phy_1", + "dp_hs_phy_2", + "dm_hs_phy_2", + "dp_hs_phy_3", + "dm_hs_phy_3", + "dp_hs_phy_4", + "dm_hs_phy_4", + "ss_phy_1", + "ss_phy_2"; + iommus = <&apps_smmu 0x800 0x0>; + phys = <&usb_2_hsphy0>, + <&usb_2_qmpphy0>; + phy-names = "usb2-0", + "usb3-0"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 803 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 804 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 805 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 138 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x820 0x0>; + phys = <&usb_0_hsphy>, + <&usb_0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 810 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 811 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 790 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 136 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x860 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sda660.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sda660.dts new file mode 100644 index 000000000000..9628fea2adff --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sda660.dts @@ -0,0 +1,59 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xccd0>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&qusb2phy0>, + <&usb3_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@c2f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0c200000 0xccd0>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&qusb2phy1>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm450.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm450.dts new file mode 100644 index 000000000000..3970f8e38e0f --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm450.dts @@ -0,0 +1,33 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@70f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8953-dwc3", "qcom,snps-dwc3"; + reg = <0x07000000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&hsusb_phy>; + phy-names = "usb2-phy"; + }; + }; + +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm630.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm630.dts new file mode 100644 index 000000000000..eaa7ed8f8062 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm630.dts @@ -0,0 +1,57 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xccd0>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&qusb2phy0>; + phy-names = "usb2-phy"; + extcon = <&extcon_usb>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@c2f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0c200000 0xccd0>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&qusb2phy1>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm632.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm632.dts new file mode 100644 index 000000000000..2c2d8e00ab78 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm632.dts @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@70f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,msm8953-dwc3", "qcom,snps-dwc3"; + reg = <0x07000000 0xd000>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "ss_phy_irq"; + phys = <&hsusb_phy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm636.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm636.dts new file mode 100644 index 000000000000..9628fea2adff --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm636.dts @@ -0,0 +1,59 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xccd0>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&qusb2phy0>, + <&usb3_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + extcon = <&extcon_usb>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@c2f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0c200000 0xccd0>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&qusb2phy1>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm660.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm660.dts new file mode 100644 index 000000000000..eaa7ed8f8062 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm660.dts @@ -0,0 +1,57 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0a800000 0xccd0>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + phys = <&qusb2phy0>; + phy-names = "usb2-phy"; + extcon = <&extcon_usb>; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@c2f8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sdm660-dwc3", "qcom,snps-dwc3"; + reg = <0x0c200000 0xccd0>; + interrupts = , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq"; + phys = <&qusb2phy1>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm670.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm670.dts new file mode 100644 index 000000000000..baf418df6b54 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm670.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm670-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845.dts new file mode 100644 index 000000000000..292ea571e040 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845.dts @@ -0,0 +1,64 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lenovo_yoga_c630.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lenovo_yoga_c630.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lenovo_yoga_c630.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyln.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyln.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyln.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyp.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyp.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_lg_judyp.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_qcom_sdm845_mtp.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_qcom_sdm845_mtp.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_qcom_sdm845_mtp.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_starqltechn.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_starqltechn.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_starqltechn.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_w737.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_w737.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_samsung_w737.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_shift_axolotl.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_shift_axolotl.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_shift_axolotl.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_thundercomm_db845c.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_thundercomm_db845c.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_thundercomm_db845c.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium_ebbg.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium_ebbg.dts new file mode 100644 index 000000000000..4226f03daba5 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdm845_xiaomi_beryllium_ebbg.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x740 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdm845-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc_intc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc_intc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x760 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx75.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx75.dts new file mode 100644 index 000000000000..b1ce092b3231 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sdx75.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sdx75-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_RISING>, + <&pdc 10 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "dwc_usb3", + "hs_phy_irq", + "ss_phy_irq", + "dm_hs_phy_irq", + "dp_hs_phy_irq"; + iommus = <&apps_smmu 0x80 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250.dts new file mode 100644 index 000000000000..a05c49f22fd3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250.dts @@ -0,0 +1,37 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sm6115-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x120 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250_oneplus_billie2.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250_oneplus_billie2.dts new file mode 100644 index 000000000000..f250d65b780a --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm4250_oneplus_billie2.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sm6115-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x120 0x0>; + phys = <&usb_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115.dts new file mode 100644 index 000000000000..a05c49f22fd3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115.dts @@ -0,0 +1,37 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sm6115-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x120 0x0>; + phys = <&usb_hsphy>, + <&usb_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115_lenovo_j606f.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115_lenovo_j606f.dts new file mode 100644 index 000000000000..f250d65b780a --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6115_lenovo_j606f.dts @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sm6115-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x120 0x0>; + phys = <&usb_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6125.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6125.dts new file mode 100644 index 000000000000..a01921cc6c13 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6125.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <1>; + #size-cells = <1>; + interrupt-parent = <&intc>; + + __overlay__ { + compatible = "qcom,sm6125-dwc3", "qcom,snps-dwc3"; + reg = <0x04e00000 0xd100>; + interrupts = , + , + , + , + ; + interrupt-names = "dwc_usb3", + "pwr_event", + "qusb2_phy", + "hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x100 0x0>; + phys = <&hsusb_phy1>; + phy-names = "usb2-phy"; + extcon = <&extcon_usb>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6350.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6350.dts new file mode 100644 index 000000000000..b5063b99fe64 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6350.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm6350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x540 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6375.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6375.dts new file mode 100644 index 000000000000..a6d83c3d913b --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm6375.dts @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@4ef8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm6375-dwc3", "qcom,snps-dwc3"; + reg = <0 0x04e00000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 255 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 302 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 254 IRQ_TYPE_LEVEL_HIGH>, + <&mpm 94 IRQ_TYPE_EDGE_BOTH>, + <&mpm 93 IRQ_TYPE_EDGE_BOTH>, + <&mpm 12 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xe0 0x0>; + phys = <&usb_1_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7125.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7125.dts new file mode 100644 index 000000000000..cd4caa173891 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7125.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7180-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x540 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7225.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7225.dts new file mode 100644 index 000000000000..b5063b99fe64 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7225.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm6350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x540 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7325.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7325.dts new file mode 100644 index 000000000000..04a9ba7a63d6 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm7325.dts @@ -0,0 +1,60 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@8cf8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x08c00000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 242 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 241 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0xa0 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sc7280-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xe400>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0xe0 0x0>; + phys = <&usb_1_hsphy>; + phy-names = "usb2-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8150.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8150.dts new file mode 100644 index 000000000000..7ce8433b3f85 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8150.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8150-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 9 IRQ_TYPE_EDGE_BOTH>, + <&pdc 8 IRQ_TYPE_EDGE_BOTH>, + <&pdc 6 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x140 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8150-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_EDGE_BOTH>, + <&pdc 7 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x160 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250.dts new file mode 100644 index 000000000000..874569a52924 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8250-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8250-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250_xiaomi_elish.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250_xiaomi_elish.dts new file mode 100644 index 000000000000..52fe5eb3f40e --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8250_xiaomi_elish.dts @@ -0,0 +1,64 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8250-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8250-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350.dts new file mode 100644 index 000000000000..f25c7d330eb2 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_microsoft_surface_duo2.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_microsoft_surface_duo2.dts new file mode 100644 index 000000000000..f25c7d330eb2 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_microsoft_surface_duo2.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_hdk.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_hdk.dts new file mode 100644 index 000000000000..a68a5bb194b3 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_hdk.dts @@ -0,0 +1,69 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + pinctrl-names = "default"; + pinctrl-0 = <&usb_hub_enabled_state>; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_mtp.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_mtp.dts new file mode 100644 index 000000000000..f25c7d330eb2 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_qcom_sm8350_mtp.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx214_generic.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx214_generic.dts new file mode 100644 index 000000000000..f25c7d330eb2 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx214_generic.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx215_generic.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx215_generic.dts new file mode 100644 index 000000000000..f25c7d330eb2 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8350_sony_pdx215_generic.dts @@ -0,0 +1,67 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8350-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 12 IRQ_TYPE_EDGE_BOTH>, + <&pdc 13 IRQ_TYPE_EDGE_BOTH>, + <&pdc 16 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x20 0x0>; + phys = <&usb_2_hsphy>, + <&usb_2_qmpphy>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8450.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8450.dts new file mode 100644 index 000000000000..c3454cc229cf --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8450.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8450-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x0 0x0>; + phys = <&usb_1_hsphy>, + <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8550.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8550.dts new file mode 100644 index 000000000000..3d94046e75ae --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8550.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8550-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x40 0x0>; + phys = <&usb_1_hsphy>, + <&usb_dp_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8650.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8650.dts new file mode 100644 index 000000000000..dd0f6a727d5c --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_sm8650.dts @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,sm8650-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 14 IRQ_TYPE_EDGE_RISING>, + <&pdc 15 IRQ_TYPE_EDGE_RISING>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "hs_phy_irq", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x40 0x0>; + phys = <&usb_1_hsphy>, + <&usb_dp_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100.dts new file mode 100644 index 000000000000..231c9b3c0357 --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100.dts @@ -0,0 +1,153 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a0f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a000000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 353 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 58 IRQ_TYPE_EDGE_BOTH>, + <&pdc 57 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x14a0 0x0>; + phys = <&usb_1_ss2_hsphy>, + <&usb_1_ss2_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a2f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a200000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 50 IRQ_TYPE_EDGE_BOTH>, + <&pdc 49 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0x14e0 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 307 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 313 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 314 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 309 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 312 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 52 IRQ_TYPE_EDGE_BOTH>, + <&pdc 51 IRQ_TYPE_EDGE_BOTH>, + <&pdc 54 IRQ_TYPE_EDGE_BOTH>, + <&pdc 53 IRQ_TYPE_EDGE_BOTH>, + <&pdc 55 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 56 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "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"; + iommus = <&apps_smmu 0x1400 0x0>; + phys = <&usb_mp_hsphy0>, + <&usb_mp_qmpphy0>, + <&usb_mp_hsphy1>, + <&usb_mp_qmpphy1>; + phy-names = "usb2-0", + "usb3-0", + "usb2-1", + "usb3-1"; + }; + }; + + fragment@3 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 355 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 61 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1420 0x0>; + phys = <&usb_1_ss0_hsphy>, + <&usb_1_ss0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@4 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 357 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 60 IRQ_TYPE_EDGE_BOTH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 47 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1460 0x0>; + phys = <&usb_1_ss1_hsphy>, + <&usb_1_ss1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100_hp_omnibook_x14.dts b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100_hp_omnibook_x14.dts new file mode 100644 index 000000000000..29e9a870c20c --- /dev/null +++ b/drivers/of/overlays/dwc3-flattening/dwc3-qcom_x1e80100_hp_omnibook_x14.dts @@ -0,0 +1,149 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. + */ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + fragment@0 { + target-path = "/soc@0/usb@a0f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a000000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 353 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 58 IRQ_TYPE_EDGE_BOTH>, + <&pdc 57 IRQ_TYPE_EDGE_BOTH>, + <&pdc 10 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x14a0 0x0>; + phys = <&usb_1_ss2_hsphy>, + <&usb_1_ss2_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@1 { + target-path = "/soc@0/usb@a2f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a200000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 50 IRQ_TYPE_EDGE_BOTH>, + <&pdc 49 IRQ_TYPE_EDGE_BOTH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq"; + iommus = <&apps_smmu 0x14e0 0x0>; + phys = <&usb_2_hsphy>; + phy-names = "usb2-phy"; + }; + }; + + fragment@2 { + target-path = "/soc@0/usb@a4f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 307 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 313 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 314 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 309 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 312 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 52 IRQ_TYPE_EDGE_BOTH>, + <&pdc 51 IRQ_TYPE_EDGE_BOTH>, + <&pdc 54 IRQ_TYPE_EDGE_BOTH>, + <&pdc 53 IRQ_TYPE_EDGE_BOTH>, + <&pdc 55 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 56 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "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"; + iommus = <&apps_smmu 0x1400 0x0>; + phys = <&usb_mp_hsphy0>, + <&usb_mp_qmpphy0>; + phy-names = "usb2-0", + "usb3-0"; + }; + }; + + fragment@3 { + target-path = "/soc@0/usb@a6f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 355 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 61 IRQ_TYPE_EDGE_BOTH>, + <&pdc 15 IRQ_TYPE_EDGE_BOTH>, + <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1420 0x0>; + phys = <&usb_1_ss0_hsphy>, + <&usb_1_ss0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; + + fragment@4 { + target-path = "/soc@0/usb@a8f8800"; + #address-cells = <2>; + #size-cells = <2>; + + __overlay__ { + compatible = "qcom,x1e80100-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0xd100>; + interrupts-extended = <&intc GIC_SPI 357 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>, + <&pdc 60 IRQ_TYPE_EDGE_BOTH>, + <&pdc 11 IRQ_TYPE_EDGE_BOTH>, + <&pdc 47 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "dwc_usb3", + "pwr_event", + "dp_hs_phy_irq", + "dm_hs_phy_irq", + "ss_phy_irq"; + iommus = <&apps_smmu 0x1460 0x0>; + phys = <&usb_1_ss1_hsphy>, + <&usb_1_ss1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", + "usb3-phy"; + }; + }; +}; From patchwork Tue Jan 14 05:11:40 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938414 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EC0962500B9 for ; Tue, 14 Jan 2025 05:06:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831186; cv=none; b=FwVZ+DP1QuvFcunUHYmHXDQDlI9MwENAh0P3w8tZwayi9pioK7Tc2ph370HOIJUHBRcO+IqPOMB0HnYTDrqw9sRjUonZrNns0he8oI2lvztS/Bjp4X6ZIOf5vO5x8py6l8EcQOiovkVOVSW8tU46FFrVVCY/pSHgIHfSMuVorsI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831186; c=relaxed/simple; bh=AuHP26w4yhegi2R/4yfc7MsQcEPJbsVzNrNbEdoBi6U=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=tWA0QLw753dnhkQYwOyJUBxQKPBpBeAx/MMmdbyCndiG5vOuG3KUDHCBv/mZR9SlGl7ktgOIvzdHwlyxvekKeluXYYrdOe/e0JOsvMWcMWXj2bJig2fvO+xK5YC1pBA7EXEUHkDAlW6t60CMduDmjJEs4BwwiH7NDI2ueN1S00g= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=GVHzyz+2; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="GVHzyz+2" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DKrXlH022928 for ; Tue, 14 Jan 2025 05:06:22 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= LHxNYTywNZiQtqTOnpGKq9gUGs6jmn3b0BzTWYuTxxw=; b=GVHzyz+2z9W7HMt/ E9gJK+9MFfeliRzz0ELFluMvsec4/HR+E1Z34vawgTPrysuzsZWwsC+cUgthK45k OtW/+MoSSfZAE+XBbnbHJ/MngNQTU9MMh5lt0SKNBvM0ZZBpNVWNpzjdi9Fd9G0M LTJYP2+FGJO9VKcUAtjloJTo9485dM4NjiYEypZ4Fn3SuUIYvD0U+gzO1TYllhs6 /i4IP39aYfLRGBD8evR2gU/dWPJhYzt7w6H7c+ZZtQwGx9wVjFQyk+aGzngVj2gA y4h+dVe/a62Y8SBr5H9rcj7Oe0lnuDEFUvLOssXVUfCgjjkYCwFIt4j5M9MlODTM AugcYA== Received: from mail-ot1-f70.google.com (mail-ot1-f70.google.com [209.85.210.70]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445a928v8a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:21 +0000 (GMT) Received: by mail-ot1-f70.google.com with SMTP id 46e09a7af769-722a1343db9so3375873a34.2 for ; Mon, 13 Jan 2025 21:06:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831168; x=1737435968; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LHxNYTywNZiQtqTOnpGKq9gUGs6jmn3b0BzTWYuTxxw=; b=jK1HS1+Dk59HGgKqcM6dVDnca0QMgybsqCJa9lbciTijy0c1WmyTB3c5z/XUSqru0P cc2mkMSg3b4TyAmkl2TMOR46x8BU9T2fUJK5TAFtg45JXf2tHaEWK+8p2l95RDYrC3+R aQxNa34nn8XCThZtYSxiL4NOUXNcO0fhsH4kK82pLo7Ma7KUqv8Kiu3jAJM+UtOZNQTC LJ9T7tbXzkIzcK2XYgfThp1ezM0bKQv2jMSr02yrqMXVqA5XK8kAsfYKhd4gpJt/UBPE d86/0GHUZ/xa14vtnUEo8bN+2Wwof7IXgdhSvJnRmO3MRR5C6/LLwvR16fNp6/Sctw/s zFAA== X-Gm-Message-State: AOJu0Yzl4G5q/jixO4l7WxOagoRbXvThA/zAKjxm4OYF1Gia5l2zq7V0 +pKAYJcVmt+Ab320OvlkierByr0O+pyShY8wXjsPUFD8pvTr3UK4MsTEnNODclY8iS3z2HxTL0G YrT/iqcyZaT8TLTNnFYHJ5zlRhtVB/OV74pyNAlfubrOn8+jo8IjQiBiHqT8da31q X-Gm-Gg: ASbGncvW6BVY9uw93+hvC993blFZJmL6A7fVafkt6C+diROjE5P6SczOvDQnu8PE3rl S4FhJ3unAZ69Sfgdp12OXLCLqv1Uq9ryt2av6JYiDe5qANEliSHw6MSdDB4r/dFCcIjN12GC6Bq FSPi8a4jMgWiYBAyQMkiBQdSo02N/qEd5jVEoFZHr+eXJsn7xTLD0wFDOXdkc6nl6/2+CUtyG7z OO+3bhhk/XzLYTES4JUEWmGS38nZrvoMMLEPuPxCd7MsFp9zBbyACE0AqF5hjvhEk/WIYK/su0+ RWHB7iZGHS/eIAm1fnNniK+TRHvShJjklzI16R60H28imOb78AZPF6aw X-Received: by 2002:a05:6830:611a:b0:71d:f9f1:7f3a with SMTP id 46e09a7af769-721e2ec9d03mr14623999a34.24.1736831167462; Mon, 13 Jan 2025 21:06:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IHnWR6Z1RNcjpuYCaWtX6P5hvwhxoRNoAimCWjyQ7z1kiDZzsM+Gn4+PXzLkz/ZlOxswztXlg== X-Received: by 2002:a05:6830:611a:b0:71d:f9f1:7f3a with SMTP id 46e09a7af769-721e2ec9d03mr14623666a34.24.1736831152553; Mon, 13 Jan 2025 21:05:52 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.05.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:05:51 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:40 -0800 Subject: [PATCH v3 07/12] of: overlays: dwc3-flattening: Provide overlay symbols Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-7-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=48679; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=AuHP26w4yhegi2R/4yfc7MsQcEPJbsVzNrNbEdoBi6U=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVwlbndoIHLJjxdNIoNXPVaSFMiaAg3EXCt N9JnNMuWWKJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcU54hAApv2Ugwcl+MqqFFVFVtEHuCl70k5rAJ//gaW4l+y PksvrHTPhxxSOXoPBtEAkDxaqYZzOWTmdGkTSqkR0Zn1IOj71GZv2KUtORw2gNeuRo+Gcq8+ak7 vS2ybcE/eFeolZ73Ggoi48jgmP/Zi/H0VRyIpfnNs4sDi8e6Yk2EXDHxfsK1PE2SV8z2w+IDssY JIQOFhXkrzWoY2V7ME0cYoBrcSrtErmIkb4b747Nus2qc0iwx++Mg+79d1AlfZ0NeLKk51MnfZ5 pGc2uv0FFetwi8IHsROIFj9DHxBipBD+lJG5QoqMlmNOiDJQGYeiPfas2Lges0k8A/cNfKosOQL xWdFeEbfAxHn+AGCjDhgmO2s6QkxPWPkuTbyoBlu5vl1n/hzQXliXzQBhRMTy6yGf+X+8AZMWV2 FOY9MPi41bh8vVdy3Xv6CJmU0xqlr1DKPytzLFgoDc+RDZtmeXuzysqSpKhYFSu2jluOcv1BNeK ybKbAZN7oLdzC/6LmJr9PzyVWSsSZkJ4v7rzUNprj2Mjgw5QSizZmGMUPEsqa8daqVbeDBzNrsJ jqNvX1KpcuFPNXk91jdLVp10QbXJlF3vfZXRhMWjN55PzYwVsr26VY/15CX6UY4+8JW09etyc6p 0z2to+wXQEBR7cBnNXLHwclT0ji8a3NYX4/RnQHu0MhE= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: 6nxk951xf94wm-nW0Z2aGeV70zQeZV9b X-Proofpoint-ORIG-GUID: 6nxk951xf94wm-nW0Z2aGeV70zQeZV9b X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 malwarescore=0 suspectscore=0 impostorscore=0 adultscore=0 priorityscore=1501 spamscore=0 lowpriorityscore=0 clxscore=1015 mlxlogscore=945 phishscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 The overlays introduced to apply the migration to the flattened Qualcomm DWC3 binding depends on symbols to be applied, but in general the DeviceTree blobs in circulation on people's devices wasn't built with symbols - and hence they can not be applied. Work around this problem by detecting when the live DeviceTree is lacking symbols and inject the necessary symbols for each target, for the duration of the dwc3-flattening overlay application. Signed-off-by: Bjorn Andersson --- .../of/overlays/dwc3-flattening/dwc3-flattening.c | 765 +++++++++++++++++++++ 1 file changed, 765 insertions(+) diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c index d33cdf6661c0..07f90360c04d 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c @@ -19,546 +19,1273 @@ struct dwc3_overlay_data { const void *fdt; const void *end; const char *migrate_match; + struct dwc3_overlay_symbol *symbols; }; static const struct dwc3_overlay_data dwc3_qcom_apq8094_overlay = { .fdt = __dtb_dwc3_qcom_apq8094_begin, .end = __dtb_dwc3_qcom_apq8094_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@f9000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_apq8096_overlay = { .fdt = __dtb_dwc3_qcom_apq8096_begin, .end = __dtb_dwc3_qcom_apq8096_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb2_id", "/usb2-id" }, + { "usb3_id", "/usb3-id" }, + { "usb3phy", "/soc@0/phy@7410000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_apq8096_inforce_ifc6640_overlay = { .fdt = __dtb_dwc3_qcom_apq8096_inforce_ifc6640_begin, .end = __dtb_dwc3_qcom_apq8096_inforce_ifc6640_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb3phy", "/soc@0/phy@7410000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq4018_overlay = { .fdt = __dtb_dwc3_qcom_ipq4018_begin, .end = __dtb_dwc3_qcom_ipq4018_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "usb2_hs_phy", "/soc/usb-phy@a8000" }, + { "usb3_hs_phy", "/soc/usb-phy@a6000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq4018_8dev_jalapeno_overlay = { .fdt = __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_begin, .end = __dtb_dwc3_qcom_ipq4018_8dev_jalapeno_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "usb2_hs_phy", "/soc/usb-phy@a8000" }, + { "usb3_hs_phy", "/soc/usb-phy@a6000" }, + { "usb3_ss_phy", "/soc/usb-phy@9a000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq4019_overlay = { .fdt = __dtb_dwc3_qcom_ipq4019_begin, .end = __dtb_dwc3_qcom_ipq4019_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "usb2_hs_phy", "/soc/usb-phy@a8000" }, + { "usb3_hs_phy", "/soc/usb-phy@a6000" }, + { "usb3_ss_phy", "/soc/usb-phy@9a000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq5018_overlay = { .fdt = __dtb_dwc3_qcom_ipq5018_begin, .end = __dtb_dwc3_qcom_ipq5018_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "usbphy0", "/soc@0/phy@5b000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq5332_overlay = { .fdt = __dtb_dwc3_qcom_ipq5332_begin, .end = __dtb_dwc3_qcom_ipq5332_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "usbphy0", "/soc@0/phy@7b000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq5424_overlay = { .fdt = __dtb_dwc3_qcom_ipq5424_begin, .end = __dtb_dwc3_qcom_ipq5424_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "qusb_phy_0", "/soc@0/phy@7b000" }, + { "qusb_phy_1", "/soc@0/phy@71000" }, + { "ssphy_0", "/soc@0/phy@7d000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq6018_overlay = { .fdt = __dtb_dwc3_qcom_ipq6018_begin, .end = __dtb_dwc3_qcom_ipq6018_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "qusb_phy_0", "/soc@0/qusb@79000" }, + { "qusb_phy_1", "/soc@0/qusb@59000" }, + { "ssphy_0", "/soc@0/ssphy@78000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq8064_overlay = { .fdt = __dtb_dwc3_qcom_ipq8064_begin, .end = __dtb_dwc3_qcom_ipq8064_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hs_phy_0", "/soc/phy@100f8800" }, + { "hs_phy_1", "/soc/phy@110f8800" }, + { "ss_phy_0", "/soc/phy@100f8830" }, + { "ss_phy_1", "/soc/phy@110f8830" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq8074_overlay = { .fdt = __dtb_dwc3_qcom_ipq8074_begin, .end = __dtb_dwc3_qcom_ipq8074_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "qusb_phy_0", "/soc@0/phy@79000" }, + { "qusb_phy_1", "/soc@0/phy@59000" }, + { "ssphy_0", "/soc@0/phy@78000" }, + { "ssphy_1", "/soc@0/phy@58000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_ipq9574_overlay = { .fdt = __dtb_dwc3_qcom_ipq9574_begin, .end = __dtb_dwc3_qcom_ipq9574_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "usb_0_qmpphy", "/soc@0/phy@7d000" }, + { "usb_0_qusbphy", "/soc@0/phy@7b000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8953_overlay = { .fdt = __dtb_dwc3_qcom_msm8953_begin, .end = __dtb_dwc3_qcom_msm8953_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy", "/soc@0/phy@79000" }, + { "intc", "/soc@0/interrupt-controller@b000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8992_overlay = { .fdt = __dtb_dwc3_qcom_msm8992_begin, .end = __dtb_dwc3_qcom_msm8992_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@f9000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8994_overlay = { .fdt = __dtb_dwc3_qcom_msm8994_begin, .end = __dtb_dwc3_qcom_msm8994_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@f9000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_begin, .end = __dtb_dwc3_qcom_msm8996_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb3phy", "/soc@0/phy@7410000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_oneplus_oneplus3_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_begin, .end = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_oneplus_oneplus3t_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_begin, .end = __dtb_dwc3_qcom_msm8996_oneplus_oneplus3t_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_dora_row_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_sony_dora_row_begin, .end = __dtb_dwc3_qcom_msm8996_sony_dora_row_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb3_id", "/usb3-id" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_kagura_row_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_sony_kagura_row_begin, .end = __dtb_dwc3_qcom_msm8996_sony_kagura_row_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb3_id", "/usb3-id" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_sony_keyaki_row_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_sony_keyaki_row_begin, .end = __dtb_dwc3_qcom_msm8996_sony_keyaki_row_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "usb3_id", "/usb3-id" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_gemini_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_gemini_begin, .end = __dtb_dwc3_qcom_msm8996_xiaomi_gemini_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "typec", "/soc@0/i2c@75b7000/typec@47" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_natrium_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_natrium_begin, .end = __dtb_dwc3_qcom_msm8996_xiaomi_natrium_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "typec", "/soc@0/i2c@75b7000/typec@47" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8996_xiaomi_scorpio_overlay = { .fdt = __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_begin, .end = __dtb_dwc3_qcom_msm8996_xiaomi_scorpio_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy1", "/soc@0/phy@7411000" }, + { "hsusb_phy2", "/soc@0/phy@7412000" }, + { "intc", "/soc@0/interrupt-controller@9bc0000" }, + { "typec", "/soc@0/i2c@75b7000/typec@47" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_begin, .end = __dtb_dwc3_qcom_msm8998_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + { "usb3phy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_fxtec_pro1_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_fxtec_pro1_begin, .end = __dtb_dwc3_qcom_msm8998_fxtec_pro1_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + { "usb3phy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_oneplus_cheeseburger_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_begin, .end = __dtb_dwc3_qcom_msm8998_oneplus_cheeseburger_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_oneplus_dumpling_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_oneplus_dumpling_begin, .end = __dtb_dwc3_qcom_msm8998_oneplus_dumpling_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_lilac_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_begin, .end = __dtb_dwc3_qcom_msm8998_sony_xperia_lilac_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + { "usb3phy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_maple_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_maple_begin, .end = __dtb_dwc3_qcom_msm8998_sony_xperia_maple_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + { "usb3phy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_sony_xperia_poplar_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_begin, .end = __dtb_dwc3_qcom_msm8998_sony_xperia_poplar_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + { "usb3phy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_msm8998_xiaomi_sagit_overlay = { .fdt = __dtb_dwc3_qcom_msm8998_xiaomi_sagit_begin, .end = __dtb_dwc3_qcom_msm8998_xiaomi_sagit_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy", "/soc@0/phy@c012000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qcm2290_overlay = { .fdt = __dtb_dwc3_qcom_qcm2290_begin, .end = __dtb_dwc3_qcom_qcm2290_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "mpm", "/remoteproc/interrupt-controller" }, + { "usb_hsphy", "/soc@0/phy@1613000" }, + { "usb_qmpphy", "/soc@0/phy@1615000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qcm6490_overlay = { .fdt = __dtb_dwc3_qcom_qcm6490_begin, .end = __dtb_dwc3_qcom_qcm6490_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qcs404_overlay = { .fdt = __dtb_dwc3_qcom_qcs404_begin, .end = __dtb_dwc3_qcom_qcs404_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@b000000" }, + { "usb2_phy_prim", "/soc@0/phy@7a000" }, + { "usb2_phy_sec", "/soc@0/phy@7c000" }, + { "usb3_phy", "/soc@0/phy@78000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qcs615_overlay = { .fdt = __dtb_dwc3_qcom_qcs615_begin, .end = __dtb_dwc3_qcom_qcs615_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_hsphy_2", "/soc@0/phy@88e3000" }, + { "usb_qmpphy", "/soc@0/phy@88e6000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qcs8300_overlay = { .fdt = __dtb_dwc3_qcom_qcs8300_begin, .end = __dtb_dwc3_qcom_qcs8300_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@8904000" }, + { "usb_2_hsphy", "/soc@0/phy@8906000" }, + { "usb_qmpphy", "/soc@0/phy@8907000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qdu1000_overlay = { .fdt = __dtb_dwc3_qcom_qdu1000_begin, .end = __dtb_dwc3_qcom_qdu1000_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17200000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e5000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_qru1000_overlay = { .fdt = __dtb_dwc3_qcom_qru1000_begin, .end = __dtb_dwc3_qcom_qru1000_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17200000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e5000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sa8155p_overlay = { .fdt = __dtb_dwc3_qcom_sa8155p_begin, .end = __dtb_dwc3_qcom_sa8155p_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb2phy_ac_en1_default", "/soc@0/pinctrl@3100000/usb2phy-ac-en1-default-state" }, + { "usb2phy_ac_en2_default", "/soc@0/pinctrl@3100000/usb2phy-ac-en2-default-state" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sa8540p_overlay = { .fdt = __dtb_dwc3_qcom_sa8540p_begin, .end = __dtb_dwc3_qcom_sa8540p_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_0_hsphy", "/soc@0/phy@88e5000" }, + { "usb_0_qmpphy", "/soc@0/phy@88eb000" }, + { "usb_1_hsphy", "/soc@0/phy@8902000" }, + { "usb_1_qmpphy", "/soc@0/phy@8903000" }, + { "usb_2_hsphy0", "/soc@0/phy@88e7000" }, + { "usb_2_hsphy1", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy2", "/soc@0/phy@88e9000" }, + { "usb_2_hsphy3", "/soc@0/phy@88ea000" }, + { "usb_2_qmpphy0", "/soc@0/phy@88ef000" }, + { "usb_2_qmpphy1", "/soc@0/phy@88f1000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sa8775p_overlay = { .fdt = __dtb_dwc3_qcom_sa8775p_begin, .end = __dtb_dwc3_qcom_sa8775p_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_0_hsphy", "/soc@0/phy@88e4000" }, + { "usb_0_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_1_hsphy", "/soc@0/phy@88e6000" }, + { "usb_1_qmpphy", "/soc@0/phy@88ea000" }, + { "usb_2_hsphy", "/soc@0/phy@88e7000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sar2130p_overlay = { .fdt = __dtb_dwc3_qcom_sar2130p_begin, .end = __dtb_dwc3_qcom_sar2130p_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17200000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_dp_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sc7180_overlay = { .fdt = __dtb_dwc3_qcom_sc7180_begin, .end = __dtb_dwc3_qcom_sc7180_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sc7280_overlay = { .fdt = __dtb_dwc3_qcom_sc7280_begin, .end = __dtb_dwc3_qcom_sc7280_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sc8180x_overlay = { .fdt = __dtb_dwc3_qcom_sc8180x_begin, .end = __dtb_dwc3_qcom_sc8180x_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_mp_hsphy0", "/soc@0/phy@88e4000" }, + { "usb_mp_hsphy1", "/soc@0/phy@88e5000" }, + { "usb_mp_qmpphy0", "/soc@0/phy@88eb000" }, + { "usb_mp_qmpphy1", "/soc@0/phy@88ec000" }, + { "usb_prim_hsphy", "/soc@0/phy@88e2000" }, + { "usb_prim_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_sec_hsphy", "/soc@0/phy@88e3000" }, + { "usb_sec_qmpphy", "/soc@0/phy@88ee000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sc8280xp_overlay = { .fdt = __dtb_dwc3_qcom_sc8280xp_begin, .end = __dtb_dwc3_qcom_sc8280xp_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_0_hsphy", "/soc@0/phy@88e5000" }, + { "usb_0_qmpphy", "/soc@0/phy@88eb000" }, + { "usb_1_hsphy", "/soc@0/phy@8902000" }, + { "usb_1_qmpphy", "/soc@0/phy@8903000" }, + { "usb_2_hsphy0", "/soc@0/phy@88e7000" }, + { "usb_2_hsphy1", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy2", "/soc@0/phy@88e9000" }, + { "usb_2_hsphy3", "/soc@0/phy@88ea000" }, + { "usb_2_qmpphy0", "/soc@0/phy@88ef000" }, + { "usb_2_qmpphy1", "/soc@0/phy@88f1000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sc8280xp_microsoft_blackrock_overlay = { .fdt = __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_begin, .end = __dtb_dwc3_qcom_sc8280xp_microsoft_blackrock_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_0_hsphy", "/soc@0/phy@88e5000" }, + { "usb_0_qmpphy", "/soc@0/phy@88eb000" }, + { "usb_1_hsphy", "/soc@0/phy@8902000" }, + { "usb_1_qmpphy", "/soc@0/phy@8903000" }, + { "usb_2_hsphy0", "/soc@0/phy@88e7000" }, + { "usb_2_qmpphy0", "/soc@0/phy@88ef000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sda660_overlay = { .fdt = __dtb_dwc3_qcom_sda660_begin, .end = __dtb_dwc3_qcom_sda660_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy0", "/soc@0/phy@c012000" }, + { "qusb2phy1", "/soc@0/phy@c014000" }, + { "usb3_qmpphy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm450_overlay = { .fdt = __dtb_dwc3_qcom_sdm450_begin, .end = __dtb_dwc3_qcom_sdm450_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy", "/soc@0/phy@79000" }, + { "intc", "/soc@0/interrupt-controller@b000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm630_overlay = { .fdt = __dtb_dwc3_qcom_sdm630_begin, .end = __dtb_dwc3_qcom_sdm630_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy0", "/soc@0/phy@c012000" }, + { "qusb2phy1", "/soc@0/phy@c014000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm632_overlay = { .fdt = __dtb_dwc3_qcom_sdm632_begin, .end = __dtb_dwc3_qcom_sdm632_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "hsusb_phy", "/soc@0/phy@79000" }, + { "intc", "/soc@0/interrupt-controller@b000000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm636_overlay = { .fdt = __dtb_dwc3_qcom_sdm636_begin, .end = __dtb_dwc3_qcom_sdm636_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy0", "/soc@0/phy@c012000" }, + { "qusb2phy1", "/soc@0/phy@c014000" }, + { "usb3_qmpphy", "/soc@0/phy@c010000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm660_overlay = { .fdt = __dtb_dwc3_qcom_sdm660_begin, .end = __dtb_dwc3_qcom_sdm660_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "extcon_usb", "/extcon-usb" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "qusb2phy0", "/soc@0/phy@c012000" }, + { "qusb2phy1", "/soc@0/phy@c014000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm670_overlay = { .fdt = __dtb_dwc3_qcom_sdm670_begin, .end = __dtb_dwc3_qcom_sdm670_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_begin, .end = __dtb_dwc3_qcom_sdm845_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_lenovo_yoga_c630_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_begin, .end = __dtb_dwc3_qcom_sdm845_lenovo_yoga_c630_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_lg_judyln_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_lg_judyln_begin, .end = __dtb_dwc3_qcom_sdm845_lg_judyln_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_lg_judyp_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_lg_judyp_begin, .end = __dtb_dwc3_qcom_sdm845_lg_judyp_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_qcom_sdm845_mtp_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_begin, .end = __dtb_dwc3_qcom_sdm845_qcom_sdm845_mtp_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_samsung_starqltechn_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_samsung_starqltechn_begin, .end = __dtb_dwc3_qcom_sdm845_samsung_starqltechn_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_samsung_w737_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_samsung_w737_begin, .end = __dtb_dwc3_qcom_sdm845_samsung_w737_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_shift_axolotl_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_shift_axolotl_begin, .end = __dtb_dwc3_qcom_sdm845_shift_axolotl_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_thundercomm_db845c_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_thundercomm_db845c_begin, .end = __dtb_dwc3_qcom_sdm845_thundercomm_db845c_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_xiaomi_beryllium_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_begin, .end = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_overlay = { .fdt = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_begin, .end = __dtb_dwc3_qcom_sdm845_xiaomi_beryllium_ebbg_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc_intc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdx55_overlay = { .fdt = __dtb_dwc3_qcom_sdx55_begin, .end = __dtb_dwc3_qcom_sdx55_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc/iommu@15000000" }, + { "intc", "/soc/interrupt-controller@17800000" }, + { "pdc", "/soc/interrupt-controller@b210000" }, + { "usb_hsphy", "/soc/phy@ff4000" }, + { "usb_qmpphy", "/soc/phy@ff6000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdx65_overlay = { .fdt = __dtb_dwc3_qcom_sdx65_begin, .end = __dtb_dwc3_qcom_sdx65_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc/iommu@15000000" }, + { "intc", "/soc/interrupt-controller@17800000" }, + { "pdc", "/soc/interrupt-controller@b210000" }, + { "usb_hsphy", "/soc/phy@ff4000" }, + { "usb_qmpphy", "/soc/phy@ff6000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sdx75_overlay = { .fdt = __dtb_dwc3_qcom_sdx75_begin, .end = __dtb_dwc3_qcom_sdx75_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17200000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_hsphy", "/soc@0/phy@ff4000" }, + { "usb_qmpphy", "/soc@0/phy@ff6000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm4250_overlay = { .fdt = __dtb_dwc3_qcom_sm4250_begin, .end = __dtb_dwc3_qcom_sm4250_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "usb_hsphy", "/soc@0/phy@1613000" }, + { "usb_qmpphy", "/soc@0/phy@1615000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm4250_oneplus_billie2_overlay = { .fdt = __dtb_dwc3_qcom_sm4250_oneplus_billie2_begin, .end = __dtb_dwc3_qcom_sm4250_oneplus_billie2_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "usb_hsphy", "/soc@0/phy@1613000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm6115_overlay = { .fdt = __dtb_dwc3_qcom_sm6115_begin, .end = __dtb_dwc3_qcom_sm6115_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "usb_hsphy", "/soc@0/phy@1613000" }, + { "usb_qmpphy", "/soc@0/phy@1615000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm6115_lenovo_j606f_overlay = { .fdt = __dtb_dwc3_qcom_sm6115_lenovo_j606f_begin, .end = __dtb_dwc3_qcom_sm6115_lenovo_j606f_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "usb_hsphy", "/soc@0/phy@1613000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm6125_overlay = { .fdt = __dtb_dwc3_qcom_sm6125_begin, .end = __dtb_dwc3_qcom_sm6125_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "extcon_usb", "/extcon-usb" }, + { "hsusb_phy1", "/soc@0/phy@1613000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm6350_overlay = { .fdt = __dtb_dwc3_qcom_sm6350_begin, .end = __dtb_dwc3_qcom_sm6350_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm6375_overlay = { .fdt = __dtb_dwc3_qcom_sm6375_begin, .end = __dtb_dwc3_qcom_sm6375_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@c600000" }, + { "intc", "/soc@0/interrupt-controller@f200000" }, + { "mpm", "/interrupt-controller" }, + { "usb_1_hsphy", "/soc@0/phy@162b000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm7125_overlay = { .fdt = __dtb_dwc3_qcom_sm7125_begin, .end = __dtb_dwc3_qcom_sm7125_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm7225_overlay = { .fdt = __dtb_dwc3_qcom_sm7225_begin, .end = __dtb_dwc3_qcom_sm7225_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm7325_overlay = { .fdt = __dtb_dwc3_qcom_sm7325_begin, .end = __dtb_dwc3_qcom_sm7325_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8150_overlay = { .fdt = __dtb_dwc3_qcom_sm8150_begin, .end = __dtb_dwc3_qcom_sm8150_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e2000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8250_overlay = { .fdt = __dtb_dwc3_qcom_sm8250_begin, .end = __dtb_dwc3_qcom_sm8250_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8250_xiaomi_elish_overlay = { .fdt = __dtb_dwc3_qcom_sm8250_xiaomi_elish_begin, .end = __dtb_dwc3_qcom_sm8250_xiaomi_elish_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8350_overlay = { .fdt = __dtb_dwc3_qcom_sm8350_begin, .end = __dtb_dwc3_qcom_sm8350_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8350_qcom_sm8350_hdk_overlay = { .fdt = __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_begin, .end = __dtb_dwc3_qcom_sm8350_qcom_sm8350_hdk_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17a00000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + { "usb_2_hsphy", "/soc@0/phy@88e4000" }, + { "usb_2_qmpphy", "/soc@0/phy@88eb000" }, + { "usb_hub_enabled_state", "/soc@0/pinctrl@f100000/usb-hub-enabled-state" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8450_overlay = { .fdt = __dtb_dwc3_qcom_sm8450_begin, .end = __dtb_dwc3_qcom_sm8450_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17100000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_1_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8550_overlay = { .fdt = __dtb_dwc3_qcom_sm8550_begin, .end = __dtb_dwc3_qcom_sm8550_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17100000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_dp_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_sm8650_overlay = { .fdt = __dtb_dwc3_qcom_sm8650_begin, .end = __dtb_dwc3_qcom_sm8650_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17100000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_hsphy", "/soc@0/phy@88e3000" }, + { "usb_dp_qmpphy", "/soc@0/phy@88e8000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_x1e80100_overlay = { .fdt = __dtb_dwc3_qcom_x1e80100_begin, .end = __dtb_dwc3_qcom_x1e80100_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17000000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_ss0_hsphy", "/soc@0/phy@fd3000" }, + { "usb_1_ss0_qmpphy", "/soc@0/phy@fd5000" }, + { "usb_1_ss1_hsphy", "/soc@0/phy@fd9000" }, + { "usb_1_ss1_qmpphy", "/soc@0/phy@fda000" }, + { "usb_1_ss2_hsphy", "/soc@0/phy@fde000" }, + { "usb_1_ss2_qmpphy", "/soc@0/phy@fdf000" }, + { "usb_2_hsphy", "/soc@0/phy@88e0000" }, + { "usb_mp_hsphy0", "/soc@0/phy@88e1000" }, + { "usb_mp_hsphy1", "/soc@0/phy@88e2000" }, + { "usb_mp_qmpphy0", "/soc@0/phy@88e3000" }, + { "usb_mp_qmpphy1", "/soc@0/phy@88e5000" }, + {} + } }; static const struct dwc3_overlay_data dwc3_qcom_x1e80100_hp_omnibook_x14_overlay = { .fdt = __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_begin, .end = __dtb_dwc3_qcom_x1e80100_hp_omnibook_x14_end, .migrate_match = "qcom,dwc3", + .symbols = (struct dwc3_overlay_symbol[]) { + { "apps_smmu", "/soc@0/iommu@15000000" }, + { "intc", "/soc@0/interrupt-controller@17000000" }, + { "pdc", "/soc@0/interrupt-controller@b220000" }, + { "usb_1_ss0_hsphy", "/soc@0/phy@fd3000" }, + { "usb_1_ss0_qmpphy", "/soc@0/phy@fd5000" }, + { "usb_1_ss1_hsphy", "/soc@0/phy@fd9000" }, + { "usb_1_ss1_qmpphy", "/soc@0/phy@fda000" }, + { "usb_1_ss2_hsphy", "/soc@0/phy@fde000" }, + { "usb_1_ss2_qmpphy", "/soc@0/phy@fdf000" }, + { "usb_2_hsphy", "/soc@0/phy@88e0000" }, + { "usb_mp_hsphy0", "/soc@0/phy@88e1000" }, + { "usb_mp_qmpphy0", "/soc@0/phy@88e3000" }, + {} + } }; static const struct of_device_id dwc3_flatten_of_match[] = { @@ -738,10 +1465,36 @@ static int dwc3_flattening_migrate(struct of_changeset *ocs, return ret; } +static int dwc3_flattening_ensure_symbols(struct of_changeset *ocs, + const struct dwc3_overlay_symbol *symbols) +{ + const struct dwc3_overlay_symbol *s; + struct device_node *symbols_np; + int ret; + + symbols_np = of_find_node_by_path("/__symbols__"); + of_node_put(symbols_np); + if (symbols_np) + return 0; + + symbols_np = of_changeset_create_node(ocs, of_root, "__symbols__"); + if (!symbols_np) + return -ENOMEM; + + for (s = symbols; s->symbol; s++) { + ret = of_changeset_add_prop_string(ocs, symbols_np, s->symbol, s->path); + if (ret) + return ret; + } + + return 0; +} + static int dwc3_flattening_init(void) { const struct dwc3_overlay_data *data; const struct of_device_id *match; + struct of_changeset symbols_ocs; struct of_changeset migrate_ocs; struct device_node *np; int overlay_ovcs; @@ -763,6 +1516,15 @@ static int dwc3_flattening_init(void) } of_node_put(np); + of_changeset_init(&symbols_ocs); + ret = dwc3_flattening_ensure_symbols(&symbols_ocs, data->symbols); + if (ret < 0) + goto out_destroy_symbols; + + ret = of_changeset_apply(&symbols_ocs); + if (ret < 0) + goto out_destroy_symbols; + of_changeset_init(&migrate_ocs); for_each_compatible_node(np, NULL, data->migrate_match) { ret = dwc3_flattening_migrate(&migrate_ocs, np); @@ -784,6 +1546,9 @@ static int dwc3_flattening_init(void) out_migrate_destroy: of_changeset_destroy(&migrate_ocs); + of_changeset_revert(&symbols_ocs); +out_destroy_symbols: + of_changeset_destroy(&symbols_ocs); return ret; } From patchwork Tue Jan 14 05:11:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938413 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C66E623A0EC for ; Tue, 14 Jan 2025 05:06:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831184; cv=none; b=ebE/+eipMzdmqvfj+NxgJHSb0j5pEQkHoqS7Sz6EjJmMJstALGhJjQIC3VaaNfWCL6KWPn0ru56zMcx0LTAwZ8I8fPSCRzwQ0JhckhKK1vx/Yi0gSxVVa8jbt2WAZeAwYYFHVuuWTdybLq4ggSaqY5gKOLO5YKRrKCo3HAYcz3Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831184; c=relaxed/simple; bh=muZkLA0Vp3J88ryGIQbBDqXzWQz+TbSF+4TbATR2OBQ=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=SVRS81PNeyt8CXuG3CAPzAPQ6aPdKYkD+pwhx2BL4G8kYXVFddczO5EwkdgLRyiXCXzzUME6XZ02RcIfUsE3hRdWy0FUigOeY2LKOiKUthsl9Vl/LL4oVvztUvuDqdWfnhXZKD1L9dCfvL8L3C+lXk5mVn8Zz3pXqtrivM93PTY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=mKjypCHV; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="mKjypCHV" Received: from pps.filterd (m0279862.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E24LcO010277 for ; Tue, 14 Jan 2025 05:06:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= as68kn4FM169poQZgZX9fA/DRIYJGHKIrl9TWXwhMPc=; b=mKjypCHVjn32jqx6 Mp1XeCd0cwqfqL2Cwaub4Y7GU+Xn0ur11uR0ibLGWgcY/lQ/NqpeJHLTRuzF8Hbh gS+21hyoFjl7P52ubxuAIhE50zhCCbCoAuU/pqGx7eB4YkpV9eP8r371S4ppyQY6 atKfyEdTnbG8aIjUkLKfRVkwPLdtX4Bebo0JHgfU6QI6S3S2rpwEjuJgmZ45zV0o EAyxPJLX/SyVsWZhm5weKF6LkwTrwGe9s0TxPM07QVlEhSE07EMJ2L9Qiuz0I/9w GcjmL0xg0dX2kHiA90EjqKIEn2FcxS1JJTQdkWu1T8eDdHh9hywNYIvXgqOsfbHi j5QRdA== Received: from mail-oo1-f70.google.com (mail-oo1-f70.google.com [209.85.161.70]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445eterbmj-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:20 +0000 (GMT) Received: by mail-oo1-f70.google.com with SMTP id 006d021491bc7-5f2e3b9c0b6so4141826eaf.2 for ; Mon, 13 Jan 2025 21:06:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831162; x=1737435962; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=as68kn4FM169poQZgZX9fA/DRIYJGHKIrl9TWXwhMPc=; b=uv5tFf/s/oyQqlY14CWAyskd+bGnNU3BzjCTj4PZ1xpHwVbEAWx+c3J0aqolQJPWe4 BZu8Ui34hUvVkzXFByKcN7qA7bWnsNIVlN77tUgo2TliZeJ7B3rw+20/wjxyfkEkRpWF hm8SQOHTO3tUp+8kRH4/tOQ+Rr+2RHLoUsMfsswocZUFrx0D+4KDfuyrtFNbysSGRVQ0 Zqr7icnLOgJjNvgQHj+dQlxPk2I+EpcRLDOtvPN+VHn5Qwk65vaWVgObqS01hRbuq6yh yjKNGOW+ssLDYnx2XJUaNRaOt70W7PzaZgrWsI7HTmmYG6RHKORSwXQRImV+Qypj7Ur5 GBZg== X-Gm-Message-State: AOJu0Yz4D3zs/H+wceyVCaW5aroMI7J3SMk3cfDi4c3PNPmuA0PmcxWD V0tzVCJD+WMBsYklBRlZjYZQ7DJKbzJxG0cfn+Tj2T750j3T1V0VmHpSOm7lSIPLEGqq04cYo4J LqKcP1n6etSKK2J+eUT+91ezF7bi3N+Pp2oLRqWQ17TEmDVpdOYoywca/zpt0J9C6 X-Gm-Gg: ASbGncsIQgX0V3zQDPAvaMhM3rW0P1KLNE6z6raoVfXQ2idwct9Ge/+1JCPuGS10sPl /O7DaLv1P4eTGqMUR3y54YTHNKbm9XvgmKQN/I5EnQA5WwQra8xvTp+GUIp+wwam5Pkg+mfr9ul j8QXogXBb+j130x+tDP/jH8KXpmwt/qayVz0Rbwg1ZFDCQZsS6KCvHvS0yNDwICMBdziTaafTXC t9pj5X9QckF5eQmk3eZnTzfmqrj1TNlY5abkM5qBwLEqWoL409vIr5Tgf+HaNhPhp6ls+aGqSAj UXdg6jJlmJ+JebNbuCpEQM0tjFXhq8dysaBIrJ+pOPruhqAE4OAwOGOE X-Received: by 2002:a05:6820:1b0b:b0:5eb:b282:5916 with SMTP id 006d021491bc7-5f73096edf3mr14815240eaf.7.1736831161685; Mon, 13 Jan 2025 21:06:01 -0800 (PST) X-Google-Smtp-Source: AGHT+IG2pGHr+Y6KnrlSZ/bxvWiXcqyB7KLMUB+V5CE73EoXohy/aAF95TpGOEhWbjfnYVpc4s8DXA== X-Received: by 2002:a05:6820:1b0b:b0:5eb:b282:5916 with SMTP id 006d021491bc7-5f73096edf3mr14815230eaf.7.1736831161336; Mon, 13 Jan 2025 21:06:01 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.06.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:06:00 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:41 -0800 Subject: [PATCH v3 08/12] usb: dwc3: core: Expose core driver as library Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-8-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=9690; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=muZkLA0Vp3J88ryGIQbBDqXzWQz+TbSF+4TbATR2OBQ=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVGwwI0V5UJxSj2BP+zu6gur5o8TxPyydFi /3PL7jKKpeJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcXQ6RAAxUC3LcXfHDnYSdkkTO+DkRdEyFhcdZdT6GFcg+V Kx/xU7LFChS8Ac9hsBIGvDs0MH1TtHLoMiwCNS4317lURk4rb58mbb+ga41GbU0hKjB+EXfIsgd z6zLPam55l3dBhre9r3tGl0ziGpf4ZB+apFeS3uPk94z4L05FYTntw1NLG75Ap61uHz4vGpAnyi WBLqUOx5rSV1J1x3LNp1eg/3J876COoP+ciNna94CC91TGDR7KmFgQNkq3qgOwN3mGtuyAN8gzf N6Ae1lw/Q8n0H35zSYgc831+rtlu+GXrZSwTqhphmGpA9Ls3V9DLVQKRw7dGEhK2jPO2T/72DXB tTCZJu77ZVXzPTzHuihH8hIs//fsoRXIynGta++FmgjGcMHvqwyW+XrKSQjJtL7ALhjQkm50kGq X+YTznsMaPDp9LDWEQpalB4DfguayDqLkCcFBpdKB7cwl4M3HFHynLW3heNOyL7QaB5hLkMGSIh 0U68CaqA3t97rJuukExFgG4WmzLSBZIYAfvy2xDEjZBRqthcXsL9fGCz9juYnPL89ANvezLbl2d wni0FWrOxWrB9xQfoILjkVPptWDrQVGFK6kszO8DI/PxE3LzbIe/E/p5C+UiD5zJMz9jWi0GiRe RL2whAjMcyJUhF6iB++ZuInE33s2qvyKKLKxb2KcZIB0= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: W-V_hnDmSS7_kSjGaDxjyAD_mBlxmJa3 X-Proofpoint-GUID: W-V_hnDmSS7_kSjGaDxjyAD_mBlxmJa3 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxlogscore=995 impostorscore=0 suspectscore=0 mlxscore=0 lowpriorityscore=0 priorityscore=1501 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 The DWC3 IP block is handled by three distinct device drivers: XHCI, DWC3 core and a platform specific (optional) DWC3 glue driver. This has resulted in, at least in the case of the Qualcomm glue, the presence of a number of layering violations, where the glue code either can't handle, or has to work around, the fact that core might not probe deterministically. An example of this is that the suspend path should operate slightly different depending on the device operating in host or peripheral mode, and the only way to determine the operating state is to peek into the core's drvdata. The Qualcomm glue driver is expected to make updates in the qscratch register region (the "glue" region) during role switch events, but with the glue and core split using the driver model, there is no reasonable way to introduce listeners for mode changes. Split the dwc3 core platform_driver callbacks and their implementation and export the implementation, to make it possible to deterministically instantiate the dwc3 core as part of the dwc3 glue drivers and to allow flattening of the DeviceTree representation. Signed-off-by: Bjorn Andersson --- drivers/usb/dwc3/core.c | 149 ++++++++++++++++++++++++++++++------------------ drivers/usb/dwc3/glue.h | 22 +++++++ 2 files changed, 117 insertions(+), 54 deletions(-) diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c index c22b8678e02e..930d812a9fbb 100644 --- a/drivers/usb/dwc3/core.c +++ b/drivers/usb/dwc3/core.c @@ -36,6 +36,7 @@ #include "core.h" #include "gadget.h" +#include "glue.h" #include "io.h" #include "debug.h" @@ -2129,27 +2130,14 @@ static int dwc3_get_num_ports(struct dwc3 *dwc) return 0; } -static int dwc3_probe(struct platform_device *pdev) +int dwc3_init(struct dwc3 *dwc, struct resource *res) { - struct device *dev = &pdev->dev; - struct resource *res, dwc_res; + struct device *dev = dwc->dev; + struct resource dwc_res; unsigned int hw_mode; void __iomem *regs; - struct dwc3 *dwc; int ret; - dwc = devm_kzalloc(dev, sizeof(*dwc), GFP_KERNEL); - if (!dwc) - return -ENOMEM; - - dwc->dev = dev; - - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!res) { - dev_err(dev, "missing memory resource\n"); - return -ENODEV; - } - dwc->xhci_resources[0].start = res->start; dwc->xhci_resources[0].end = dwc->xhci_resources[0].start + DWC3_XHCI_REGS_END; @@ -2209,7 +2197,7 @@ static int dwc3_probe(struct platform_device *pdev) goto err_disable_clks; } - platform_set_drvdata(pdev, dwc); + dev_set_drvdata(dev, dwc); dwc3_cache_hwparams(dwc); if (!dwc->sysdev_is_parent && @@ -2304,12 +2292,31 @@ static int dwc3_probe(struct platform_device *pdev) return ret; } +EXPORT_SYMBOL_GPL(dwc3_init); -static void dwc3_remove(struct platform_device *pdev) +static int dwc3_probe(struct platform_device *pdev) { - struct dwc3 *dwc = platform_get_drvdata(pdev); + struct resource *res; + struct dwc3 *dwc; + + res = platform_get_resource(pdev, IORESOURCE_MEM, 0); + if (!res) { + dev_err(&pdev->dev, "missing memory resource\n"); + return -ENODEV; + } + + dwc = devm_kzalloc(&pdev->dev, sizeof(*dwc), GFP_KERNEL); + if (!dwc) + return -ENOMEM; - pm_runtime_get_sync(&pdev->dev); + dwc->dev = &pdev->dev; + + return dwc3_init(dwc, res); +} + +void dwc3_uninit(struct dwc3 *dwc) +{ + pm_runtime_get_sync(dwc->dev); dwc3_core_exit_mode(dwc); dwc3_debugfs_exit(dwc); @@ -2317,22 +2324,28 @@ static void dwc3_remove(struct platform_device *pdev) dwc3_core_exit(dwc); dwc3_ulpi_exit(dwc); - pm_runtime_allow(&pdev->dev); - pm_runtime_disable(&pdev->dev); - pm_runtime_dont_use_autosuspend(&pdev->dev); - pm_runtime_put_noidle(&pdev->dev); + pm_runtime_allow(dwc->dev); + pm_runtime_disable(dwc->dev); + pm_runtime_dont_use_autosuspend(dwc->dev); + pm_runtime_put_noidle(dwc->dev); /* * HACK: Clear the driver data, which is currently accessed by parent * glue drivers, before allowing the parent to suspend. */ - platform_set_drvdata(pdev, NULL); - pm_runtime_set_suspended(&pdev->dev); + dev_set_drvdata(dwc->dev, NULL); + pm_runtime_set_suspended(dwc->dev); dwc3_free_event_buffers(dwc); if (dwc->usb_psy) power_supply_put(dwc->usb_psy); } +EXPORT_SYMBOL_GPL(dwc3_uninit); + +static void dwc3_remove(struct platform_device *pdev) +{ + dwc3_uninit(platform_get_drvdata(pdev)); +} #ifdef CONFIG_PM static int dwc3_core_init_for_resume(struct dwc3 *dwc) @@ -2521,9 +2534,8 @@ static int dwc3_runtime_checks(struct dwc3 *dwc) return 0; } -static int dwc3_runtime_suspend(struct device *dev) +int dwc3_runtime_suspend(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); int ret; if (dwc3_runtime_checks(dwc)) @@ -2535,10 +2547,10 @@ static int dwc3_runtime_suspend(struct device *dev) return 0; } +EXPORT_SYMBOL_GPL(dwc3_runtime_suspend); -static int dwc3_runtime_resume(struct device *dev) +int dwc3_runtime_resume(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); int ret; ret = dwc3_resume_common(dwc, PMSG_AUTO_RESUME); @@ -2559,15 +2571,14 @@ static int dwc3_runtime_resume(struct device *dev) break; } - pm_runtime_mark_last_busy(dev); + pm_runtime_mark_last_busy(dwc->dev); return 0; } +EXPORT_SYMBOL_GPL(dwc3_runtime_resume); -static int dwc3_runtime_idle(struct device *dev) +int dwc3_runtime_idle(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); - switch (dwc->current_dr_role) { case DWC3_GCTL_PRTCAP_DEVICE: if (dwc3_runtime_checks(dwc)) @@ -2579,50 +2590,65 @@ static int dwc3_runtime_idle(struct device *dev) break; } - pm_runtime_mark_last_busy(dev); - pm_runtime_autosuspend(dev); + pm_runtime_mark_last_busy(dwc->dev); + pm_runtime_autosuspend(dwc->dev); return 0; } +EXPORT_SYMBOL_GPL(dwc3_runtime_idle); + +static int dwc3_plat_runtime_suspend(struct device *dev) +{ + return dwc3_runtime_suspend(dev_get_drvdata(dev)); +} + +static int dwc3_plat_runtime_resume(struct device *dev) +{ + return dwc3_runtime_resume(dev_get_drvdata(dev)); +} + +static int dwc3_plat_runtime_idle(struct device *dev) +{ + return dwc3_runtime_idle(dev_get_drvdata(dev)); +} #endif /* CONFIG_PM */ #ifdef CONFIG_PM_SLEEP -static int dwc3_suspend(struct device *dev) +int dwc3_suspend(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); int ret; ret = dwc3_suspend_common(dwc, PMSG_SUSPEND); if (ret) return ret; - pinctrl_pm_select_sleep_state(dev); + pinctrl_pm_select_sleep_state(dwc->dev); return 0; } +EXPORT_SYMBOL_GPL(dwc3_suspend); -static int dwc3_resume(struct device *dev) +int dwc3_resume(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); int ret = 0; - pinctrl_pm_select_default_state(dev); + pinctrl_pm_select_default_state(dwc->dev); - pm_runtime_disable(dev); - pm_runtime_set_active(dev); + pm_runtime_disable(dwc->dev); + pm_runtime_set_active(dwc->dev); ret = dwc3_resume_common(dwc, PMSG_RESUME); if (ret) - pm_runtime_set_suspended(dev); + pm_runtime_set_suspended(dwc->dev); - pm_runtime_enable(dev); + pm_runtime_enable(dwc->dev); return ret; } +EXPORT_SYMBOL_GPL(dwc3_resume); -static void dwc3_complete(struct device *dev) +void dwc3_complete(struct dwc3 *dwc) { - struct dwc3 *dwc = dev_get_drvdata(dev); u32 reg; if (dwc->current_dr_role == DWC3_GCTL_PRTCAP_HOST && @@ -2632,21 +2658,36 @@ static void dwc3_complete(struct device *dev) dwc3_writel(dwc->regs, DWC3_GUCTL3, reg); } } +EXPORT_SYMBOL_GPL(dwc3_complete); + +static int dwc3_plat_suspend(struct device *dev) +{ + return dwc3_suspend(dev_get_drvdata(dev)); +} + +static int dwc3_plat_resume(struct device *dev) +{ + return dwc3_resume(dev_get_drvdata(dev)); +} + +static void dwc3_plat_complete(struct device *dev) +{ + dwc3_complete(dev_get_drvdata(dev)); +} #else -#define dwc3_complete NULL +#define dwc3_plat_complete NULL #endif /* CONFIG_PM_SLEEP */ static const struct dev_pm_ops dwc3_dev_pm_ops = { - SET_SYSTEM_SLEEP_PM_OPS(dwc3_suspend, dwc3_resume) - .complete = dwc3_complete, - + SET_SYSTEM_SLEEP_PM_OPS(dwc3_plat_suspend, dwc3_plat_resume) + .complete = dwc3_plat_complete, /* * Runtime suspend halts the controller on disconnection. It relies on * platforms with custom connection notification to start the controller * again. */ - SET_RUNTIME_PM_OPS(dwc3_runtime_suspend, dwc3_runtime_resume, - dwc3_runtime_idle) + SET_RUNTIME_PM_OPS(dwc3_plat_runtime_suspend, dwc3_plat_runtime_resume, + dwc3_plat_runtime_idle) }; #ifdef CONFIG_OF diff --git a/drivers/usb/dwc3/glue.h b/drivers/usb/dwc3/glue.h new file mode 100644 index 000000000000..f6a513e43f53 --- /dev/null +++ b/drivers/usb/dwc3/glue.h @@ -0,0 +1,22 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * glue.h - DesignWare USB3 DRD glue header + */ + +#ifndef __DRIVERS_USB_DWC3_GLUE_H +#define __DRIVERS_USB_DWC3_GLUE_H + +#include +#include "core.h" + +int dwc3_init(struct dwc3 *dwc, struct resource *res); +void dwc3_uninit(struct dwc3 *dwc); + +int dwc3_runtime_suspend(struct dwc3 *dwc); +int dwc3_runtime_resume(struct dwc3 *dwc); +int dwc3_runtime_idle(struct dwc3 *dwc); +int dwc3_suspend(struct dwc3 *dwc); +int dwc3_resume(struct dwc3 *dwc); +void dwc3_complete(struct dwc3 *dwc); + +#endif From patchwork Tue Jan 14 05:11:42 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938411 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 91CF32451CE for ; Tue, 14 Jan 2025 05:06:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831182; cv=none; b=nQ6DUI/STGhBBg/6qnN3leyN8seh/wrWSm0owoQVjrJDXjGkvu1qvTKCj7AU6gh70IaDAQ10mU1+7JwsROtO/IquH4DxB1oyNpNeINxYbZvOT/jsPKjfGCngVTNfj9M5BwBY0qsVrw7k3L/zadFNXdOS2h+REiy1qRJiwXzGToU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831182; c=relaxed/simple; bh=M8a05g5QhGIDQGcQr0ozZere4otNUOUy0SpBYsjJCpI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=m49tLH9IsX9g30eBuhAiMFbrkQvk0v7xPaIJbOgUCKpEoPYT5vvRUTyvJLw8hdhAMW7+PW83hr/PDBWTPwAPbLgwslrdEH8mwyNpZGkjhmxJQxPeGFHX7+9WcErnE0k6siIm3HWSHttgPTBspGAHKt+Zq3zUttWfOU2UuOH0qfo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=hIJJlZsO; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="hIJJlZsO" Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E27SD8027639 for ; Tue, 14 Jan 2025 05:06:19 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= qbPNDUgAq9khxXzdnGO7xYrRsfNyJmja9qPh+54W2wg=; b=hIJJlZsOOlO5wOJI 7/zNmwU7s/GoQ5NekgyVAVhx1utvGYpbBjJfbfAI2xnp4Md+o/JDJu9fTNjHNtle apbfydlCInZ/Z/8/tM9lad0rMqgWriU7cHB2lRJt6fStJ0dmwZ07a7DN6YjdASjg YyDYBg6jQMa2nqYcDGuuW4gHuU6566p5ndjcH9ezc/OGIPc3zVHZUF20M47hRbPl wr8gDkyPlVO4iNfkT/1Z1kVGFAbXXJ0V+Oet6/Kie6J2+LzaIj4HAq4R6qoOOkHq k7wtj6+NRj+YN9UH8sVAjmXhgdlnQpWgVgjaYOemNlBLgO5dN7EmR33IUWf8DX1i N0sJgg== Received: from mail-oo1-f69.google.com (mail-oo1-f69.google.com [209.85.161.69]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445ev78bdn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:18 +0000 (GMT) Received: by mail-oo1-f69.google.com with SMTP id 006d021491bc7-5f88020f6f9so3669739eaf.3 for ; Mon, 13 Jan 2025 21:06:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831162; x=1737435962; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qbPNDUgAq9khxXzdnGO7xYrRsfNyJmja9qPh+54W2wg=; b=ZWGyjAUpSvEjWlJqDnOfXfryU6aLGEXyX4AnojIRmfISOOwG4a/THm59ynTh6RGlrG wP3QZjpJIQV5YTDi8bptJ/qlHL2wjHBtFMWglP+ocYSJ+SV4POca7iLYJhtJJLVqItXB r9963rVvVQyUfBo/W+qDnjruCobZJaZnO+KYlb8VIPLwEo+GtcPlyGiEe3vT2UMrMOJg VATiExLlP9DjhpT1ZZudk0SqcpSwUGuUvT1r+PtYXlSGxBePxCZEFUU5NTfNiy9dVk6u K2MJZp0zpSerGFuXAF6vAz+j3ZIyynryL1FEOW1w0q/wt6haDXAuezyF+sc56h52Rjn+ Fgwg== X-Gm-Message-State: AOJu0YwSLU23amH95ctzyb/K8fmeE116KrzXm2IxxhH5hTFKkVtQy/pc maC96jQUOfnKImuZWZVUAmh7sNRqVJTJN0JTiAAYZ0MIL0KPsk88ggI0AsNccRSTlTXDk/W4QLY pZLWKQsbF7goY27DoHCvP4lAIM2QvY6wnxWpY/holeFn/SdZBl9Pnduo2oNnvTh3u+/Aex59A X-Gm-Gg: ASbGncuRAsJ0J/Z6tDyDx0d5aCqhBimBNh+IM5hNrKRNggAjP7JvgQKnnYDNWRv+bet iCTul6CVkGh++Vq0xOqe4o4nL84NOx/1TmiCTu9hwOcWsD81uY5CZY3rAgMRXtx1ofXJ6xRrDM/ 0yQaDrv0Brbto6XgH30EmTI63+rbyxk2erdB88hJx70xAwegbr7ICFC75ulbGBCOkKkqD/eRuDn yTxubqnqx4h2TqPfEGV0JT7YrSswUN0n7iugR3owIpNVFd8ybz7iiAP7GAA/M+mbHX1PQ1/vo9v 6i1+I02SqlB7p7bKkrtKEJGHztMArwm/CY9WCK9nYAeNV4w9STYnv4uF X-Received: by 2002:a05:6820:210e:b0:5f6:8c7e:f59e with SMTP id 006d021491bc7-5f730989363mr16287571eaf.6.1736831162758; Mon, 13 Jan 2025 21:06:02 -0800 (PST) X-Google-Smtp-Source: AGHT+IFnfKXoeeeA8NBKomAIGTBbHrl8rTKa1hnJ9t51uButBIKoClFHi11qMo2YLC0zEXH94GPIrw== X-Received: by 2002:a05:6820:210e:b0:5f6:8c7e:f59e with SMTP id 006d021491bc7-5f730989363mr16287554eaf.6.1736831162451; Mon, 13 Jan 2025 21:06:02 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.06.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:06:01 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:42 -0800 Subject: [PATCH v3 09/12] usb: dwc3: core: Don't touch resets and clocks Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-9-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2329; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=M8a05g5QhGIDQGcQr0ozZere4otNUOUy0SpBYsjJCpI=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVOsfUzZ+vsMvlEhHlwzfQcaWwEzB0h35m9 R0ifsSqmjiJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcXZ9RAA0iQqg0EmNJYeqqOjc0dfJ1H7b0UIC3sUd0vmjr4 hAHB6O0u19HbWk3nE443PWV0bPSiDznlnH+L8kuLoo7CzouLyZjIu0tICAzB8V3iGU+KnfxpzXu 1bC5DRQkKOYA/R+oDE+/dY37NUMq+ftw9umdwfjdGR4is5oTtvcoXbuN/Rrf4JEIUXhgtY68Kr9 YLCDzYyCOrm5MKDLXWXcNDHg3Rk2vF5F4Ra6PmfrL+RLg/l0HvKL4SdSm7y9VFnNspfdiJIGyxw QLVzgNVif7flOHOzxgmA6gnrZoZKHxxkjxF6EdQCNP1yCoKMCI48EtX1zvhpkaeoyBKD+I4bjMN 7Rn2rBrE29msQRpAnwuRC+GBt0pTPXEopaQT7B7SEJAL2NPYqUHyUE0p4nuGF/NBSS6IYmdEz0O lJI+IfPVQSLErZn2sM9HBAMl5GKcL+HMDtxeggHULotixy2mj2fYhAPLUpopCRhN9XFTnQvBzlw 0NF22KdtnvPyO/GYtR1oWgYdgAnyYYegodpLiZUMdzq3+SjJP4IALcLyQAoC4/2w8/LKJOqVhvl 3rjh9RYXOA1F3VGwyi2P9Z/hesplGvUFMR6PAjbI1HwzCCfz/NmHi/gpae5gDvBDr669vVxneyM J30LQrxIKUlzQXxto9hIwajsle3z8plZRYo7uwZj//Rg= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: -6qq6xlUTpNGwR0CVxq5sPkTVHVya2vt X-Proofpoint-GUID: -6qq6xlUTpNGwR0CVxq5sPkTVHVya2vt X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 spamscore=0 adultscore=0 clxscore=1015 bulkscore=0 mlxscore=0 phishscore=0 mlxlogscore=999 suspectscore=0 lowpriorityscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 When the core is integrated with glue, it's expected that the glue IP will require, and hence handle, the clocks and resets of the IP-block. Allow the platform or glue layer to indicate if the core logic for clocks and resets should be skipped to deal with this. Signed-off-by: Bjorn Andersson --- drivers/usb/dwc3/core.c | 22 ++++++++++++---------- drivers/usb/dwc3/glue.h | 2 +- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c index 930d812a9fbb..c0b2398b8c18 100644 --- a/drivers/usb/dwc3/core.c +++ b/drivers/usb/dwc3/core.c @@ -2130,7 +2130,7 @@ static int dwc3_get_num_ports(struct dwc3 *dwc) return 0; } -int dwc3_init(struct dwc3 *dwc, struct resource *res) +int dwc3_init(struct dwc3 *dwc, struct resource *res, bool ignore_clocks_and_resets) { struct device *dev = dwc->dev; struct resource dwc_res; @@ -2173,15 +2173,17 @@ int dwc3_init(struct dwc3 *dwc, struct resource *res) dwc3_get_software_properties(dwc); - dwc->reset = devm_reset_control_array_get_optional_shared(dev); - if (IS_ERR(dwc->reset)) { - ret = PTR_ERR(dwc->reset); - goto err_put_psy; - } + if (!ignore_clocks_and_resets) { + dwc->reset = devm_reset_control_array_get_optional_shared(dev); + if (IS_ERR(dwc->reset)) { + ret = PTR_ERR(dwc->reset); + goto err_put_psy; + } - ret = dwc3_get_clocks(dwc); - if (ret) - goto err_put_psy; + ret = dwc3_get_clocks(dwc); + if (ret) + goto err_put_psy; + } ret = reset_control_deassert(dwc->reset); if (ret) @@ -2311,7 +2313,7 @@ static int dwc3_probe(struct platform_device *pdev) dwc->dev = &pdev->dev; - return dwc3_init(dwc, res); + return dwc3_init(dwc, res, false); } void dwc3_uninit(struct dwc3 *dwc) diff --git a/drivers/usb/dwc3/glue.h b/drivers/usb/dwc3/glue.h index f6a513e43f53..ac87491bfdeb 100644 --- a/drivers/usb/dwc3/glue.h +++ b/drivers/usb/dwc3/glue.h @@ -9,7 +9,7 @@ #include #include "core.h" -int dwc3_init(struct dwc3 *dwc, struct resource *res); +int dwc3_init(struct dwc3 *dwc, struct resource *res, bool ignore_clocks_and_resets); void dwc3_uninit(struct dwc3 *dwc); int dwc3_runtime_suspend(struct dwc3 *dwc); From patchwork Tue Jan 14 05:11:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938412 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1BAF924635E for ; Tue, 14 Jan 2025 05:06:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831184; cv=none; b=aR6OR3J9JUIonPItlEXs9+gBVfd8mFycehOzNa5wwhDHRg9cv3alSoCedYawDmU4E7v2mOgFi3VtLg/vXovLv1RJSQ3SB+w3q/QRHkTCw8jdUZPoMHi5TyHMXZkTZ68v1ebeS3jBUNaGupRumYzJVRdAlgIItgJZT3HavZt2xjA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831184; c=relaxed/simple; bh=XMhUGa9jASilaYKmAqPhGJDF9Z/4W7QRLCZ3ziNou6Y=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=mSJx3w9ewgPFEzl5EB7sZk4casU5RKMUZ8FahPMlb4g4O0vfWm7SPS6OkckWGRg6lxONgMMVGVNre/rRMvcZHPCf3B9Jtph/mV1dUIedq4B/IIjYH8e5LpOgeBUlg8E7wg29FYrPcZRO8BK6h3Sr0UFfrPYqLEPOfbAs0NlgA2I= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=QSVd4DAs; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="QSVd4DAs" Received: from pps.filterd (m0279862.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E24LcS010277 for ; Tue, 14 Jan 2025 05:06:21 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= I+pBckYQT8kiWYR+JN/p8P4x1oQKu26Ua1lLR/Lpzog=; b=QSVd4DAsKdwYaYgf 3vvU5PHmgkLUkNimXdrG1zL2dsOXFhz6GoRAAExKjWVItfRD3G2eH7Qx0SgYz4A7 Yet++oGsXDB30qyWpWFuAZKV/moRfDx8586fUlkjiUnpdSekmssF/eBf/JeO4q7Z FaMWqmb3GDPa6u8OfQXP9Y0RC95GfdfdKNvxgAO2jTrfDhGtn25FTBsUduoRjEpI hMS6oT5I5l5GMmtUAdCtd1tFewNhs87Rhlefw/+TPTK8dE+ncfYfwQnqq19WYl3b 4u8Ll/XqRvI1KUZKViWv5YudWZnP48xI/Tf4jUZr/lhw3PIwtvqR6lm2Z9zBG8Ly IpiQWw== Received: from mail-oa1-f72.google.com (mail-oa1-f72.google.com [209.85.160.72]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445eterbmt-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:20 +0000 (GMT) Received: by mail-oa1-f72.google.com with SMTP id 586e51a60fabf-29e61ef3897so3565362fac.1 for ; Mon, 13 Jan 2025 21:06:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831164; x=1737435964; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=I+pBckYQT8kiWYR+JN/p8P4x1oQKu26Ua1lLR/Lpzog=; b=XL9UNMAu+22IbZN5guEvMMO01PTiTvBZQVtI5n9bBHnC9LOOkd4X9AnDtkbLNQkj43 b9MgeTVYQfNzbXHTeCgHwFZAnFsJX556wxfE6MDR01fuT7nkaSxlgev/tK+4YLXvo0aS YN2erYgm54S5Ea6iH7kFeJNR8I2zuqWyLcr4kmekNO97rs6o0F8fcYy1d4d+qwkPxGHO +iRQ21pXRL+u2dklynSmXIsU+qFnLrCF/FRezretB9MfHfxi/xjXxupxRjBPPNeCLwzs HHxZIDmVFVQjHpyNBT3XSWPVlLBWhXgVzFejk1HI4lkPKgrAVGL8mnz2dJck/jcbM4P0 goWw== X-Gm-Message-State: AOJu0YxWBsJATtj8n1o8Gf2ju95JUSn2Ls49EUUxaDcNERHO0BikimBQ Iq1D7e+S3x6bfBrsi6hTtqVKJgsFfYHLqRQMdu4u5Izg4th7vv4X+rTDb5KM+NnUDbGHNopQo0y fKC9j0DvatI8Arya5bMkJtvhpKzv7sDQokXpWoN9zl/2pVOlyfyylzliT/iOc2Gzh X-Gm-Gg: ASbGncvqyWMx+rAf2V/gZlW/TYVMvRBqj0i3v/qS779JE+RHGmBE3uzXEp7F2hdf0PZ vlXDJdw4WfIMV6rj1/l7l3gFN1EybRVf/Y59tj0SKV/L3WUihfQCnWYNEtT2+TNSx4gpUBvnKjt yzoADOBSnwmlJ4sh7zeM8e9lgCxNR9aYVdGcI4mowSRhJja5OWi1dus3TfEbPlvViLuwa/IApec NSBHvzsskQSYJ0R3inOh19rtHBn+Vp7Ox/LOPyGSmZ33RIx6lgKk7A5lQgITme2xRf/ZDaFkZ62 AqPk6uKp+y6jnngJmUl7kpibJuJau+3dX1oij5xFlgi5+zLulDHwscS3 X-Received: by 2002:a05:6820:1745:b0:5f2:ae23:767 with SMTP id 006d021491bc7-5f73070b54emr12596455eaf.0.1736831163824; Mon, 13 Jan 2025 21:06:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IGbssb+eGXtilc3CQwmUCInY0FJo024TV9q9MgOQ1o2yh8BjC4LvpO8WQxaIXj/9OPLVL5LDQ== X-Received: by 2002:a05:6820:1745:b0:5f2:ae23:767 with SMTP id 006d021491bc7-5f73070b54emr12596444eaf.0.1736831163517; Mon, 13 Jan 2025 21:06:03 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.06.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:06:03 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:43 -0800 Subject: [PATCH v3 10/12] usb: dwc3: qcom: Don't rely on drvdata during probe Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-10-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3028; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=XMhUGa9jASilaYKmAqPhGJDF9Z/4W7QRLCZ3ziNou6Y=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIV5pP9H4VjRY3SSghjy9khuqpLriBrkV5Mk c3mImvjAoCJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcWiIxAA3ix6QgOfLXqse2uIvzzXX+PnesgNISy7rEC4vRx IJ+ja8hGVH3KEXq75BzF5HIUnVcO4fZNXgPKJeujbboK0MNEg47Rexnjr2K2Jd0yvexT+9t3axr GZoCF3ZeeWixsL3xl4bxF0ii4AN5Cnz13zCVeGaMDSh1AMMJUZ8q84jUG55FQiJ7/ZmTsP8bt+I 6JwlogNEv1FqsvRGEftz3jmkRF8HAz7m0VW9MDY0IgsX8VtBX3MNMvjXK6g8ZhXBF7iktQZLaYY NcTvDwz1H0roZ87gXrUMttokFuynDWnhie3KDaenMKqZRlzqHEJGJv8JQLPhJNhXsb9IyOnk2QM 7rW7IZtgxae+KTr0Y1JfquJ+l+FOQBdfbXm5kvrp2irW4Zt8CzqD3oEzmuJUFO42/JqQEpIqS27 1qd3uuWlOTIcwJbm250B0owWg12wul45gPA0C3TIpxzW2Bb+hhx26jmOnXv3ij6SWTin3zwzzj/ R7sHoCpOjvyI1tydlTcKdPl3ZkKcyLvOAB5PQKKtMdvRkDXgYhZdGMBnwU0D5ikWA7MRujqWFJx 4NQ1QcopQdfWyYN1XalT6ubUvOVmc0wPLzcpIeNefv5e45UaqSsRBEpK8Yeo52TelEG8Heduc3/ TVet5aqRZx5IM/tUNkpe6vO7Do7atDcvoa05Z86VFxGI= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: DfGvje8ZjcNyeI0Gb_VrBsqygizml2AT X-Proofpoint-GUID: DfGvje8ZjcNyeI0Gb_VrBsqygizml2AT X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxlogscore=999 impostorscore=0 suspectscore=0 mlxscore=0 lowpriorityscore=0 priorityscore=1501 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 With the upcoming transition to a model where DWC3 core and glue operate on a single struct device the drvdata datatype will change to be owned by the core. The drvdata is however used by the Qualcomm DWC3 glue to pass the qcom glue context around before the core is allocated. Remove this problem, and clean up the code, by passing the dwc3_qcom struct around during probe, instead of acquiring it from the drvdata. Signed-off-by: Bjorn Andersson --- drivers/usb/dwc3/dwc3-qcom.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/drivers/usb/dwc3/dwc3-qcom.c b/drivers/usb/dwc3/dwc3-qcom.c index 58683bb672e9..50b1da845113 100644 --- a/drivers/usb/dwc3/dwc3-qcom.c +++ b/drivers/usb/dwc3/dwc3-qcom.c @@ -547,9 +547,10 @@ static int dwc3_qcom_request_irq(struct dwc3_qcom *qcom, int irq, return ret; } -static int dwc3_qcom_setup_port_irq(struct platform_device *pdev, int port_index, bool is_multiport) +static int dwc3_qcom_setup_port_irq(struct dwc3_qcom *qcom, + struct platform_device *pdev, + int port_index, bool is_multiport) { - struct dwc3_qcom *qcom = platform_get_drvdata(pdev); const char *irq_name; int irq; int ret; @@ -634,9 +635,8 @@ static int dwc3_qcom_find_num_ports(struct platform_device *pdev) return DWC3_QCOM_MAX_PORTS; } -static int dwc3_qcom_setup_irq(struct platform_device *pdev) +static int dwc3_qcom_setup_irq(struct dwc3_qcom *qcom, struct platform_device *pdev) { - struct dwc3_qcom *qcom = platform_get_drvdata(pdev); bool is_multiport; int ret; int i; @@ -645,7 +645,7 @@ static int dwc3_qcom_setup_irq(struct platform_device *pdev) is_multiport = (qcom->num_ports > 1); for (i = 0; i < qcom->num_ports; i++) { - ret = dwc3_qcom_setup_port_irq(pdev, i, is_multiport); + ret = dwc3_qcom_setup_port_irq(qcom, pdev, i, is_multiport); if (ret) return ret; } @@ -700,9 +700,8 @@ static int dwc3_qcom_clk_init(struct dwc3_qcom *qcom, int count) return 0; } -static int dwc3_qcom_of_register_core(struct platform_device *pdev) +static int dwc3_qcom_of_register_core(struct dwc3_qcom *qcom, struct platform_device *pdev) { - struct dwc3_qcom *qcom = platform_get_drvdata(pdev); struct device_node *np = pdev->dev.of_node; struct device *dev = &pdev->dev; int ret; @@ -778,7 +777,7 @@ static int dwc3_qcom_probe(struct platform_device *pdev) goto clk_disable; } - ret = dwc3_qcom_setup_irq(pdev); + ret = dwc3_qcom_setup_irq(qcom, pdev); if (ret) { dev_err(dev, "failed to setup IRQs, err=%d\n", ret); goto clk_disable; @@ -793,7 +792,7 @@ static int dwc3_qcom_probe(struct platform_device *pdev) if (ignore_pipe_clk) dwc3_qcom_select_utmi_clk(qcom); - ret = dwc3_qcom_of_register_core(pdev); + ret = dwc3_qcom_of_register_core(qcom, pdev); if (ret) { dev_err(dev, "failed to register DWC3 Core, err=%d\n", ret); goto clk_disable; From patchwork Tue Jan 14 05:11:44 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938410 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CFD58237A3B for ; Tue, 14 Jan 2025 05:06:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831178; cv=none; b=tfG8jocbGIJcmTGq/nTGRarmrW7bVTyGkUR/xwg35dyYbmo2u+dhxXhyDRA1+VOuuJ/BswkVCy2kH4GU7bt9F99Oj0Bl5NGIuBwRaRxNYjSXcbQG19tOZzhP8CGgvD54u44V8MOGMCI++9OinVZDPOr2CzamNg4phAHOyEQvq0Y= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831178; c=relaxed/simple; bh=jlR6+ARwM/Lr0teTiCl1CKnctX2uH9kwYJiHn4/8YKg=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=C9xVuxgPxjJ/sJk+zJ+Pmg6o6Ao9MjV0pDj9if80bos3lZlpoSSwyyhZKzvDzq+U/i7pPFNaDdYxE3e8H1pGNabdJIIdKPqgyU5TQyNX2QMHGDQSVJWdnlcjJFbQbtrb22ogyEASe8sMBGvApHjc26DjrZXd+JmhrQrYPz/BQEQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=DSJ9/9GG; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="DSJ9/9GG" Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50DJLZl7002853 for ; Tue, 14 Jan 2025 05:06:15 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= wVofHqa/Meq48kmXydox7fcxL/v6GrgcWjFrX0DvEHE=; b=DSJ9/9GGoaSIOZom E2qWTn23GWKiPwTT1EG41yhWugpnWdK76D55Ly/8jiB3K60x3xTtv1vEP3guZaox 7k4jmqe1JDhA821imkFOp0aCBd08TN8W0Rln7aT4Rjz4LdnhDUzAK+LIdmy1eL7I 26n14HNcHZCDUKmfWJfny298cY03J31q0XL1zwGdTIPgnhST0t/JTsEbz8yc9Pz0 2gFwauz9lT3QzJe63bYbXgxxVvvd3rR2i8EQJIELoMXwPXpBhpB0ccimwBGEdZHr ZCtBNuCRFj6gWB3isdh1ey7MltKWSfpqPRcr3ML2Z1UJ4UQpghRX4aY97S3/a31n 4zuZlg== Received: from mail-oo1-f70.google.com (mail-oo1-f70.google.com [209.85.161.70]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4458ww92eg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:14 +0000 (GMT) Received: by mail-oo1-f70.google.com with SMTP id 006d021491bc7-5f368647450so3782661eaf.0 for ; Mon, 13 Jan 2025 21:06:14 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831165; x=1737435965; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wVofHqa/Meq48kmXydox7fcxL/v6GrgcWjFrX0DvEHE=; b=jIc9vgubHFoipiSue+yMXjEGrdN2r9zlJPk7hGrvsJweswlEIavAFS1ACUxZLjJJaP HlT14FFbzYJkZcutV3WGl+GL3cFrsvxUIk+xX/wunYd3eYjqTL8YzxyfOacGWyqyqZOf G5mgK00DBnK5UWu/UbN7dyMXs8mDPRBls2EZcUkc1D4f/NY2C/z8kgUgjvNa+YLixwa2 5sUm6XGfHLpohqvjUOcOWVIKp5on/qqajOWis2SReX+ncbJu/w0n9yTXUMjtCnvPtvUM 8eZU7CMNFpMa1so+DZlVnFZbNUyIqlPz4GkhQadOm9eFn2LF+yeKJ9i8E0v78dkDk1CH 0dtg== X-Gm-Message-State: AOJu0YwDb+iWs3pVHhkJ88GGBvGzOAKGxGvg6xNOmxmfOYYl4qiiaO4c o0Egjt8LHYw/KKhIrCGixtF2iWNb5ul7xq8KZc2NL1dqmiyw3hv1TdyCk+sYObxr2ZHH/8iHisg aR0GpKbjuginjUtOXPaCFRJbffO/F0q7BcK+OrFwfu/dMlG8UjvsD0qerre72w2Sv X-Gm-Gg: ASbGncthkPOqGHZiizW+hM4iPTFIBQK8S4HI5ZCmB3Gsjjv1AS9896tLLWjtbFFem0j CyqjGmCb0dLL9LdZQylx6qHBwrxfQa83RZdLwR887SgG1WTnk5Zq6xAF+09VXR2J9r9JEswn17w RnVGTina+A6radOnnjI33dsLFEya0X04krFJcqtFp8yZcHJxfW8dLT9AS8EehwXsOjrPunBw00R VYjzMthAuY2sBfcSou12cJHC++k0msxuTJBLPOl1BwF90m9vTv93I0MuSqflwlVBiZPVC8wc+9U c9imXmk/hb1VAcCDNQRrOIZi2J0Ze/KKm40LAiVGzY0x6cJdK7eDCLv7 X-Received: by 2002:a4a:b18c:0:b0:5f7:339c:27a3 with SMTP id 006d021491bc7-5f7339c2a17mr10442484eaf.2.1736831165096; Mon, 13 Jan 2025 21:06:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IFqwl+eWCMyO3CPeK27lGBS3soliNfv/oFDlsvsyLoUOt2edrVJrjKWfLPHuUuRhDEwv+gaWQ== X-Received: by 2002:a4a:b18c:0:b0:5f7:339c:27a3 with SMTP id 006d021491bc7-5f7339c2a17mr10442472eaf.2.1736831164686; Mon, 13 Jan 2025 21:06:04 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.06.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:06:04 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:44 -0800 Subject: [PATCH v3 11/12] usb: dwc3: qcom: Transition to flattened model Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-11-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=12227; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=jlR6+ARwM/Lr0teTiCl1CKnctX2uH9kwYJiHn4/8YKg=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVF8ZS6KvJ35selAj1vSpjlZm3Yeq9BWchE bCGp6PFz96JAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcXySxAArHI/3Zvmt0ED3fxHD4ZMqHAT0B3JgArgbUgZRjE 4Y3nZaS85rWC5dvHXyLDraiWhb0QRR98qJJ0syGjbLN4+MYjX+BZyvnPjfBGHSEN+CHyXqBXEuM OR2zb/k8luHfhX6cghWBNusirfXcrHQ74wnv2PECTk1KQtbnuQ3fx0JCxJcVsMEgxaesV4g680T 2wAc8ueRWvVhTqDSXodcmGwWkPaS/zPMneRGBcbcBsTvxVfDXtbvwLxYa090scSvrj+md9NxdoV mxA6lR0iOGfhrg9M+jQsyJ690Xzo1Rf0UCZefuRbhLm0lGx9P+AK1x34JG3MPEEig2SfDoY4/Dz p0KfOwXC9yXM4OFyW6Z8ElMxbkECBXfc5VAQl1d45RJHQrpZpvaTHFtNUzqBzFS8tORuX+7ssos +EbMuX6arRYPaVQM+IhLrJXGdU/4E/VSZ69ck97nL2wdZnxL46+4KWGQKtahDK8nPqgMG3v0vXr jIfo3zuq7WODv6TanIEFbYm05Bq/+4k2WOKYN+BAXuyzwptwtf+tmDKzAIAeN8nGRkreViUelDb EoVe2CdiuKXcOKOipttVacU/lOsgaX58XiodEXqP2Ssv5tKj9VzCzfD0O7FOkCA6NqZt8VyRYyf XmaLpKUslNELRTmrhxy2B/0bieZOyi99pF8dsqR9RIqA= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-GUID: cWcUF_g_MZY-owrfsYAbNb0TLAJH9Bz6 X-Proofpoint-ORIG-GUID: cWcUF_g_MZY-owrfsYAbNb0TLAJH9Bz6 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 spamscore=0 mlxlogscore=999 mlxscore=0 clxscore=1015 impostorscore=0 malwarescore=0 adultscore=0 bulkscore=0 phishscore=0 suspectscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 The USB IP-block found in most Qualcomm platforms is modelled in the Linux kernel as 3 different independent device drivers, but as shown by the already existing layering violations in the Qualcomm glue driver they can not be operated independently. With the current implementation, the glue driver registers the core and has no way to know when this is done. As a result, e.g. the suspend callbacks needs to guard against NULL pointer dereferences when trying to peek into the struct dwc3 found in the drvdata of the child. Even with these checks, there are no way to fully protect ourselves from the race conditions that occur if the DWC3 is unbound. Missing from the upstream Qualcomm USB support is handling of role switching, in which the glue needs to be notified upon DRD mode changes. Several attempts has been made through the years to register callbacks etc, but they always fall short when it comes to handling of the core's probe deferral on resources etc. Moving to a model where the DWC3 core is instantiated in a synchronous fashion avoids above described race conditions. It is however not feasible to do so without also flattening the DeviceTree binding, as assumptions are made in the DWC3 core and frameworks used that the device's associated of_node will the that of the core. Furthermore, the DeviceTree binding is a direct representation of the Linux driver model, and doesn't necessarily describe "the USB IP-block". The Qualcomm DWC3 glue driver is therefor transitioned to initialize and operate the DWC3 within the one device context, in synchronous fashion. To handle backwards compatibility, and to remove the two-device model, of_nodes of the old compatible are converted to the new one, early during probe. This happens in the event that a DWC3 core child node is present, the content of the reg and interrupt properties of this node are merged into the shared properties, all remaining properties are copied and the core node is dropped. Effectively transitioning the node from qcom,dwc3 to qcom,snps-dwc3. As the dwc3-qcom driver is migrated to support (and only support) the qcom,snps-dwc3 binding, the kill-switch in the dwc3-flattening overlay code is removed. Signed-off-by: Bjorn Andersson --- .../of/overlays/dwc3-flattening/dwc3-flattening.c | 3 - drivers/usb/dwc3/dwc3-qcom.c | 136 ++++++++++----------- 2 files changed, 66 insertions(+), 73 deletions(-) diff --git a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c index 07f90360c04d..44bc97ac53c0 100644 --- a/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c +++ b/drivers/of/overlays/dwc3-flattening/dwc3-flattening.c @@ -1500,9 +1500,6 @@ static int dwc3_flattening_init(void) int overlay_ovcs; int ret; - /* TODO: Remove kill-switch as dwc3-qcom is migrated to qcom,snps-dwc */ - return 0; - match = of_match_node(dwc3_flatten_of_match, of_root); if (!match) return 0; diff --git a/drivers/usb/dwc3/dwc3-qcom.c b/drivers/usb/dwc3/dwc3-qcom.c index 50b1da845113..df1ee6961c9e 100644 --- a/drivers/usb/dwc3/dwc3-qcom.c +++ b/drivers/usb/dwc3/dwc3-qcom.c @@ -14,7 +14,8 @@ #include #include #include -#include +#include +#include #include #include #include @@ -23,6 +24,7 @@ #include #include #include "core.h" +#include "glue.h" /* USB QSCRATCH Hardware registers */ #define QSCRATCH_HS_PHY_CTRL 0x10 @@ -73,7 +75,7 @@ struct dwc3_qcom_port { struct dwc3_qcom { struct device *dev; void __iomem *qscratch_base; - struct platform_device *dwc3; + struct dwc3 dwc; struct clk **clks; int num_clocks; struct reset_control *resets; @@ -92,6 +94,8 @@ struct dwc3_qcom { struct icc_path *icc_path_apps; }; +#define to_dwc3_qcom(d) container_of((d), struct dwc3_qcom, dwc) + static inline void dwc3_qcom_setbits(void __iomem *base, u32 offset, u32 val) { u32 reg; @@ -260,7 +264,7 @@ static int dwc3_qcom_interconnect_init(struct dwc3_qcom *qcom) goto put_path_ddr; } - max_speed = usb_get_maximum_speed(&qcom->dwc3->dev); + max_speed = usb_get_maximum_speed(qcom->dwc.dev); if (max_speed >= USB_SPEED_SUPER || max_speed == USB_SPEED_UNKNOWN) { ret = icc_set_bw(qcom->icc_path_ddr, USB_MEMORY_AVG_SS_BW, USB_MEMORY_PEAK_SS_BW); @@ -303,25 +307,14 @@ static void dwc3_qcom_interconnect_exit(struct dwc3_qcom *qcom) /* Only usable in contexts where the role can not change. */ static bool dwc3_qcom_is_host(struct dwc3_qcom *qcom) { - struct dwc3 *dwc; - - /* - * FIXME: Fix this layering violation. - */ - dwc = platform_get_drvdata(qcom->dwc3); - - /* Core driver may not have probed yet. */ - if (!dwc) - return false; - - return dwc->xhci; + return qcom->dwc.xhci; } static enum usb_device_speed dwc3_qcom_read_usb2_speed(struct dwc3_qcom *qcom, int port_index) { - struct dwc3 *dwc = platform_get_drvdata(qcom->dwc3); struct usb_device *udev; struct usb_hcd __maybe_unused *hcd; + struct dwc3 *dwc = &qcom->dwc; /* * FIXME: Fix this layering violation. @@ -498,7 +491,7 @@ static int dwc3_qcom_resume(struct dwc3_qcom *qcom, bool wakeup) static irqreturn_t qcom_dwc3_resume_irq(int irq, void *data) { struct dwc3_qcom *qcom = data; - struct dwc3 *dwc = platform_get_drvdata(qcom->dwc3); + struct dwc3 *dwc = &qcom->dwc; /* If pm_suspended then let pm_resume take care of resuming h/w */ if (qcom->pm_suspended) @@ -700,40 +693,13 @@ static int dwc3_qcom_clk_init(struct dwc3_qcom *qcom, int count) return 0; } -static int dwc3_qcom_of_register_core(struct dwc3_qcom *qcom, struct platform_device *pdev) -{ - struct device_node *np = pdev->dev.of_node; - struct device *dev = &pdev->dev; - int ret; - - struct device_node *dwc3_np __free(device_node) = of_get_compatible_child(np, - "snps,dwc3"); - if (!dwc3_np) { - dev_err(dev, "failed to find dwc3 core child\n"); - return -ENODEV; - } - - ret = of_platform_populate(np, NULL, NULL, dev); - if (ret) { - dev_err(dev, "failed to register dwc3 core - %d\n", ret); - return ret; - } - - qcom->dwc3 = of_find_device_by_node(dwc3_np); - if (!qcom->dwc3) { - ret = -ENODEV; - dev_err(dev, "failed to get dwc3 platform device\n"); - of_platform_depopulate(dev); - } - - return ret; -} - static int dwc3_qcom_probe(struct platform_device *pdev) { struct device_node *np = pdev->dev.of_node; struct device *dev = &pdev->dev; struct dwc3_qcom *qcom; + struct resource res; + struct resource *r; int ret, i; bool ignore_pipe_clk; bool wakeup_source; @@ -742,7 +708,6 @@ static int dwc3_qcom_probe(struct platform_device *pdev) if (!qcom) return -ENOMEM; - platform_set_drvdata(pdev, qcom); qcom->dev = &pdev->dev; qcom->resets = devm_reset_control_array_get_optional_exclusive(dev); @@ -771,8 +736,15 @@ static int dwc3_qcom_probe(struct platform_device *pdev) goto reset_assert; } - qcom->qscratch_base = devm_platform_ioremap_resource(pdev, 0); + r = platform_get_resource(pdev, IORESOURCE_MEM, 0); + if (!r) + goto clk_disable; + res = *r; + res.end = res.start + SDM845_QSCRATCH_BASE_OFFSET; + + qcom->qscratch_base = devm_ioremap(dev, res.end, SDM845_QSCRATCH_SIZE); if (IS_ERR(qcom->qscratch_base)) { + dev_err(dev, "failed to map qscratch region: %pe\n", qcom->qscratch_base); ret = PTR_ERR(qcom->qscratch_base); goto clk_disable; } @@ -792,17 +764,18 @@ static int dwc3_qcom_probe(struct platform_device *pdev) if (ignore_pipe_clk) dwc3_qcom_select_utmi_clk(qcom); - ret = dwc3_qcom_of_register_core(qcom, pdev); - if (ret) { - dev_err(dev, "failed to register DWC3 Core, err=%d\n", ret); + qcom->dwc.dev = dev; + ret = dwc3_init(&qcom->dwc, &res, true); + if (ret) { + ret = dev_err_probe(dev, ret, "failed to register DWC3 Core\n"); goto clk_disable; } ret = dwc3_qcom_interconnect_init(qcom); if (ret) - goto depopulate; + goto remove_core; - qcom->mode = usb_get_dr_mode(&qcom->dwc3->dev); + qcom->mode = usb_get_dr_mode(dev); /* enable vbus override for device mode */ if (qcom->mode != USB_DR_MODE_HOST) @@ -815,20 +788,15 @@ static int dwc3_qcom_probe(struct platform_device *pdev) wakeup_source = of_property_read_bool(dev->of_node, "wakeup-source"); device_init_wakeup(&pdev->dev, wakeup_source); - device_init_wakeup(&qcom->dwc3->dev, wakeup_source); qcom->is_suspended = false; - pm_runtime_set_active(dev); - pm_runtime_enable(dev); - pm_runtime_forbid(dev); return 0; interconnect_exit: dwc3_qcom_interconnect_exit(qcom); -depopulate: - of_platform_depopulate(&pdev->dev); - platform_device_put(qcom->dwc3); +remove_core: + dwc3_uninit(&qcom->dwc); clk_disable: for (i = qcom->num_clocks - 1; i >= 0; i--) { clk_disable_unprepare(qcom->clks[i]); @@ -842,13 +810,11 @@ static int dwc3_qcom_probe(struct platform_device *pdev) static void dwc3_qcom_remove(struct platform_device *pdev) { - struct dwc3_qcom *qcom = platform_get_drvdata(pdev); + struct dwc3 *dwc = platform_get_drvdata(pdev); + struct dwc3_qcom *qcom = to_dwc3_qcom(dwc); struct device *dev = &pdev->dev; int i; - of_platform_depopulate(&pdev->dev); - platform_device_put(qcom->dwc3); - for (i = qcom->num_clocks - 1; i >= 0; i--) { clk_disable_unprepare(qcom->clks[i]); clk_put(qcom->clks[i]); @@ -864,10 +830,15 @@ static void dwc3_qcom_remove(struct platform_device *pdev) static int __maybe_unused dwc3_qcom_pm_suspend(struct device *dev) { - struct dwc3_qcom *qcom = dev_get_drvdata(dev); + struct dwc3 *dwc = dev_get_drvdata(dev); + struct dwc3_qcom *qcom = to_dwc3_qcom(dwc); bool wakeup = device_may_wakeup(dev); int ret; + ret = dwc3_suspend(&qcom->dwc); + if (ret) + return ret; + ret = dwc3_qcom_suspend(qcom, wakeup); if (ret) return ret; @@ -879,7 +850,8 @@ static int __maybe_unused dwc3_qcom_pm_suspend(struct device *dev) static int __maybe_unused dwc3_qcom_pm_resume(struct device *dev) { - struct dwc3_qcom *qcom = dev_get_drvdata(dev); + struct dwc3 *dwc = dev_get_drvdata(dev); + struct dwc3_qcom *qcom = to_dwc3_qcom(dwc); bool wakeup = device_may_wakeup(dev); int ret; @@ -889,31 +861,55 @@ static int __maybe_unused dwc3_qcom_pm_resume(struct device *dev) qcom->pm_suspended = false; + ret = dwc3_resume(&qcom->dwc); + if (ret) + return ret; + return 0; } static int __maybe_unused dwc3_qcom_runtime_suspend(struct device *dev) { - struct dwc3_qcom *qcom = dev_get_drvdata(dev); + struct dwc3 *dwc = dev_get_drvdata(dev); + struct dwc3_qcom *qcom = to_dwc3_qcom(dwc); + int ret; + + ret = dwc3_runtime_suspend(&qcom->dwc); + if (ret) + return ret; return dwc3_qcom_suspend(qcom, true); } +static void __maybe_unused dwc3_qcom_complete(struct device *dev) +{ + struct dwc3 *dwc = dev_get_drvdata(dev); + + dwc3_complete(dwc); +} + static int __maybe_unused dwc3_qcom_runtime_resume(struct device *dev) { - struct dwc3_qcom *qcom = dev_get_drvdata(dev); + struct dwc3 *dwc = dev_get_drvdata(dev); + struct dwc3_qcom *qcom = to_dwc3_qcom(dwc); + int ret; + + ret = dwc3_qcom_resume(qcom, true); + if (ret) + return ret; - return dwc3_qcom_resume(qcom, true); + return dwc3_runtime_resume(&qcom->dwc); } static const struct dev_pm_ops dwc3_qcom_dev_pm_ops = { SET_SYSTEM_SLEEP_PM_OPS(dwc3_qcom_pm_suspend, dwc3_qcom_pm_resume) SET_RUNTIME_PM_OPS(dwc3_qcom_runtime_suspend, dwc3_qcom_runtime_resume, NULL) + .complete = dwc3_qcom_complete, }; static const struct of_device_id dwc3_qcom_of_match[] = { - { .compatible = "qcom,dwc3" }, + { .compatible = "qcom,snps-dwc3" }, { } }; MODULE_DEVICE_TABLE(of, dwc3_qcom_of_match); From patchwork Tue Jan 14 05:11:45 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 13938409 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6F5A5235BFC for ; Tue, 14 Jan 2025 05:06:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831177; cv=none; b=BYO3NXS9K9OYMyLnQ4g1XsX6qQssmMazN6VxmOfYuHIMzOD4Cz8ej4+dHEoZVpY344XSAKwjljCwWkdaZYy4NaZju6mQYwcRLtlkAyorcvsMKX8L7+Dtn+iDQQ8HY60si2ENKnf4aS7z3QQi9vno7b9ru4chzg9kja/X3F1Meh0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736831177; c=relaxed/simple; bh=QZCpZlu53quw6nL6TnKxy5fmS1nRzhqSoUP2GUKX9/c=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=qjhrZDLw0eezVWU8D23qW3l5NhwKakWm2OAei3Uwda4CrJDMHVvpdw2JiQLtS6tm6s2F6Ybg6WVW660QunUdpOJV08nku4NG6Z7ikp45IKFPHWf4McrQJJBevi0iX0NJW0v2Z6mJEg6CY8Ce4f9DHlmnYeHoyp3E+MkJwuVtWCs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=KGf7NYt4; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="KGf7NYt4" Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 50E41GQ0021780 for ; Tue, 14 Jan 2025 05:06:13 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= 7sVaiMs2t/yghLl4ZXum6gfPzebES0AYVlGI7YtV98s=; b=KGf7NYt4oOGnRDHO wwN0i9O/t7QZJqhpGXfDqSvWdbX4t5XeO1SGPHQ/EoCZDXsrkIy8wnd0/GJ93jQz 18XlEk4s7uCheAWgA/zsVVk7fYzCH8m8blH2XJrAUHG0ELjWuY7PTHtq2MkTrxrT EDy626Yfc0AFQHyATsOLhyhwSn6KLYdP92uJ3kQBXlb3+7oS2q0GCuenmVAditBX vO/T/kbf/NLsUFlz7KhPjX7FdBVi+Dm80/VljM09/cYWNL/pFNBMhlrmSwKSW1tL ulvORhyfpJmoPpy3POInnXExNsIqcvfe9duFocTaJf5uNMcj7A0Ge1V7up7GuVzh pgh6uA== Received: from mail-oo1-f72.google.com (mail-oo1-f72.google.com [209.85.161.72]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 445gh603c8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Tue, 14 Jan 2025 05:06:13 +0000 (GMT) Received: by mail-oo1-f72.google.com with SMTP id 006d021491bc7-5f336936512so3569191eaf.3 for ; Mon, 13 Jan 2025 21:06:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736831166; x=1737435966; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=7sVaiMs2t/yghLl4ZXum6gfPzebES0AYVlGI7YtV98s=; b=e5dJvU3svVHE/NP6cnVk15C7dduG67Tvr7faR+Sg3d4sZ0xAT113JDHTTbKnezSrQh J+bN9PH1cwaU93nENct5lAcDTJ1uTF5KLY+PE6kJEDMvoqGsTRBPm/VX/wk8D8Fe2pZ1 q4qaEnavEhYDXRT16+rTMohvCq4waVdXLI9WCoDDYorb5lgHbyOmtabaUmbEVVs+ne7F g0cSJF+esgbVBGxXHWxf4WOXsAnqACXr1r6n7kVDMqqW+bfgcKCsrkQp3XWhnNS/ivkV bp/ifmRRxdR4nHycp89pvzQTw7X0aVXkgshiA/zkp4X/o8QyIIKr6mHYcCmlseNNPJfG dBWw== X-Gm-Message-State: AOJu0YwAWVt3pTJJVH343bcs+DSm3ozBhScQoZR6RD5YFx55O1XiIrvv wEmGIjt/L8z3adbNhUfa8JdaRtTwlyn76NDyaKD3BvR1P/oEzOcehUHR+xOeesQErj/LkujAZwf p10ETdwy+f4HvEea2iuCRq/jb5KqK4Wu23tavDMr5kj9nkM0QqHR4tUqTHtu3Uj8c X-Gm-Gg: ASbGnctCTAXhjRNtrb02HPUNV6255oaf81kwyPIjA793q4VU1ZYLCBTFf75t4PTlH4G ICIP1gaiCOF5HvuoLJis90I7eyCYa9pAkY5462xiWLRSm5NA3wz6RqGDT9AjlyKP+XG05VWOXGB 3Xk0viBx03Rl0hQgqUKIcKu3YQtpQ0J2ye3EGQmUV6/nUeoszDgsfjDcAMHu6daCIFJQdNP/Rww swUg8884gIxaBVY/WmedMsSLwV7VuB//AKf32BNDLN/vkSuCJU2uWBuAX1sCHRdXLgwfi8TMeKd 7nwn7j+Pqka9Id2qKPiNrxcu/9pQ4yVCDfiKl6bYM3cPrCEz4zv+svXj X-Received: by 2002:a05:6820:c92:b0:5f8:b916:2516 with SMTP id 006d021491bc7-5f8b91627fbmr3634059eaf.0.1736831166223; Mon, 13 Jan 2025 21:06:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IEmEHuVW5qi2sAI1oDKa1nMWAv2Gy9K/Nus/ICcutZpYln8LjviPaQBro2NNf9FeuBaY8drYA== X-Received: by 2002:a05:6820:c92:b0:5f8:b916:2516 with SMTP id 006d021491bc7-5f8b91627fbmr3634048eaf.0.1736831165840; Mon, 13 Jan 2025 21:06:05 -0800 (PST) Received: from [192.168.86.65] (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-5f882756603sm4001750eaf.29.2025.01.13.21.06.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 21:06:05 -0800 (PST) From: Bjorn Andersson Date: Mon, 13 Jan 2025 21:11:45 -0800 Subject: [PATCH v3 12/12] arm64: dts: qcom: sc8280x: Flatten the USB nodes Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250113-dwc3-refactor-v3-12-d1722075df7b@oss.qualcomm.com> References: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> In-Reply-To: <20250113-dwc3-refactor-v3-0-d1722075df7b@oss.qualcomm.com> To: Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Felipe Balbi , Wesley Cheng , Saravana Kannan , Thinh Nguyen , Philipp Zabel , Bjorn Andersson , Konrad Dybcio , Frank Li Cc: linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bjorn Andersson X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=13628; i=bjorn.andersson@oss.qualcomm.com; h=from:subject:message-id; bh=QZCpZlu53quw6nL6TnKxy5fmS1nRzhqSoUP2GUKX9/c=; b=owEBgwJ8/ZANAwAIAQsfOT8Nma3FAcsmYgBnhfIVd3y2cF3CBIEhCUos5UwVC6LpTGBrNcMcM jJsSfDrykKJAkkEAAEIADMWIQQF3gPMXzXqTwlm1SULHzk/DZmtxQUCZ4XyFRUcYW5kZXJzc29u QGtlcm5lbC5vcmcACgkQCx85Pw2ZrcWzgA//Waq1cGSgv95hOttvPTD7GbCp6dOzDOe/tgWFHRu DH1v3Ci83L/ardMEoT0NmeZ74dGw6JTgwwiboJjDJlG2M77vEFH4mRjWarUeUR+CO9QK7AbrAG9 V9QUrItL2bVZkULHRth8qmbnK9+9jdsFL3lRN8bkRA5RoUCOPlBx7trVY+/jQ4RHfurnTUQaHMc GRIX8c5Zd3Gsf3gdpimu6w4TV2UyRplL60Wlb4VRSoIjsPqi8F9RaqzQfx59Xr0eCCcyMI3cwyC 2jN6APDFKj1QipC/VrmIRiSTOH583/ltUs231+PuAqTcRiSARHlqh0zCAqMmaR6nl214U3IenR8 3SrIZSvS/iqE79EdS7dscCt9Q4lacUHdJ5pTCdyk+gokEzblLFPbEGvIRUoS1ew/rb5fkLtufr2 YX6Wd4yLMxEoe8LAU7NM4zkggAMQ2noC0CXTTqTPZUMlTPaFsoY7AWNPnkiCcejavNiffYh8Gtf 79mPjzL4C0Aad6l7ztAvxXybEMcZkHYhzCe3wjULdlN5DTBzNIsuQ+ewfkWfFhLlQaZWTdO0eXX h70ws80mOwPWRaIUt9bRo/jxUO8aKoFWJtslKlTXUhzduW6ITTF+krYsstD76mkPZfecQm6eHW3 db6yaB8AskzXOIfcTCoY29c9QG7qNTv4x5bACIVtOcFo= X-Developer-Key: i=bjorn.andersson@oss.qualcomm.com; a=openpgp; fpr=05DE03CC5F35EA4F0966D5250B1F393F0D99ADC5 X-Proofpoint-ORIG-GUID: wrUdbD5cKw49YchyIzVvIqhE3zAcqSYo X-Proofpoint-GUID: wrUdbD5cKw49YchyIzVvIqhE3zAcqSYo X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.60.29 definitions=2024-09-06_09,2024-09-06_01,2024-09-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 mlxscore=0 suspectscore=0 malwarescore=0 mlxlogscore=999 phishscore=0 clxscore=1015 spamscore=0 lowpriorityscore=0 priorityscore=1501 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2501140040 Transition the three USB controllers found in sc8280xp to the newly introduced, flattened representation of the Qualcomm USB block, i.e. qcom,snps-dwc3, to show the end result. The reg and interrupts properties from the usb child node are merged with their counterpart in the outer node, remaining properties and child nodes are simply moved. Signed-off-by: Bjorn Andersson --- arch/arm64/boot/dts/qcom/sa8295p-adp.dts | 12 +- arch/arm64/boot/dts/qcom/sa8540p-ride.dts | 5 +- arch/arm64/boot/dts/qcom/sc8280xp-crd.dts | 12 +- .../boot/dts/qcom/sc8280xp-huawei-gaokun3.dts | 10 +- .../dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts | 11 +- .../boot/dts/qcom/sc8280xp-microsoft-arcata.dts | 10 +- .../boot/dts/qcom/sc8280xp-microsoft-blackrock.dts | 18 +-- arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 157 ++++++++++----------- 8 files changed, 95 insertions(+), 140 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sa8295p-adp.dts b/arch/arm64/boot/dts/qcom/sa8295p-adp.dts index 2fd1dafe63ce..3d84cbf5af31 100644 --- a/arch/arm64/boot/dts/qcom/sa8295p-adp.dts +++ b/arch/arm64/boot/dts/qcom/sa8295p-adp.dts @@ -631,12 +631,10 @@ &ufs_card_phy { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { /* TODO: Define USB-C connector properly */ dr_mode = "peripheral"; + + status = "okay"; }; &usb_0_hsphy { @@ -655,12 +653,10 @@ &usb_0_qmpphy { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { /* TODO: Define USB-C connector properly */ dr_mode = "host"; + + status = "okay"; }; &usb_1_hsphy { diff --git a/arch/arm64/boot/dts/qcom/sa8540p-ride.dts b/arch/arm64/boot/dts/qcom/sa8540p-ride.dts index 177b9dad6ff7..7be803fb7cbe 100644 --- a/arch/arm64/boot/dts/qcom/sa8540p-ride.dts +++ b/arch/arm64/boot/dts/qcom/sa8540p-ride.dts @@ -466,11 +466,8 @@ &ufs_mem_phy { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "peripheral"; + status = "okay"; }; &usb_0_hsphy { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-crd.dts b/arch/arm64/boot/dts/qcom/sc8280xp-crd.dts index 75adaa19d1c3..05fe5793f1f1 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-crd.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-crd.dts @@ -795,11 +795,9 @@ &ufs_mem_phy { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "host"; + + status = "okay"; }; &usb_0_dwc3_hs { @@ -832,11 +830,9 @@ &usb_0_qmpphy_out { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { dr_mode = "host"; + + status = "okay"; }; &usb_1_dwc3_hs { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-huawei-gaokun3.dts b/arch/arm64/boot/dts/qcom/sc8280xp-huawei-gaokun3.dts index 09b95f89ee58..300c7dc999a4 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-huawei-gaokun3.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-huawei-gaokun3.dts @@ -997,11 +997,8 @@ bluetooth { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "host"; + status = "okay"; }; &usb_0_hsphy { @@ -1026,11 +1023,8 @@ &usb_0_qmpphy_dp_in { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { dr_mode = "host"; + status = "okay"; }; &usb_1_hsphy { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts b/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts index f3190f408f4b..1b9501cc82f4 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts @@ -1343,11 +1343,9 @@ bluetooth { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "host"; + + status = "okay"; }; &usb_0_dwc3_hs { @@ -1380,11 +1378,8 @@ &usb_0_qmpphy_out { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { dr_mode = "host"; + status = "okay"; }; &usb_1_dwc3_hs { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-arcata.dts b/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-arcata.dts index ae5daeac8fe2..82672f441ea2 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-arcata.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-arcata.dts @@ -749,11 +749,8 @@ embedded-controller { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "host"; + status = "okay"; }; &usb_0_dwc3_hs { @@ -786,11 +783,8 @@ &usb_0_qmpphy_out { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { dr_mode = "host"; + status = "okay"; }; &usb_1_dwc3_hs { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-blackrock.dts b/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-blackrock.dts index fa9d94105052..eeb69cfd4422 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-blackrock.dts +++ b/arch/arm64/boot/dts/qcom/sc8280xp-microsoft-blackrock.dts @@ -982,11 +982,9 @@ bluetooth { }; &usb_0 { - status = "okay"; -}; - -&usb_0_dwc3 { dr_mode = "host"; + + status = "okay"; }; &usb_0_dwc3_hs { @@ -1019,11 +1017,9 @@ &usb_0_qmpphy_out { }; &usb_1 { - status = "okay"; -}; - -&usb_1_dwc3 { dr_mode = "host"; + + status = "okay"; }; &usb_1_dwc3_hs { @@ -1059,12 +1055,10 @@ &usb_2 { pinctrl-0 = <&usb2_en_state>; pinctrl-names = "default"; - status = "okay"; -}; - -&usb_2_dwc3 { phys = <&usb_2_hsphy0>, <&usb_2_qmpphy0>; phy-names = "usb2-0", "usb3-0"; + + status = "okay"; }; &usb_2_hsphy0 { diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi index 01501acb1790..3dea86b0e13d 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi +++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi @@ -3457,12 +3457,9 @@ system-cache-controller@9200000 { interrupts = ; }; - usb_2: usb@a4f8800 { - compatible = "qcom,sc8280xp-dwc3-mp", "qcom,dwc3"; - reg = <0 0x0a4f8800 0 0x400>; - #address-cells = <2>; - #size-cells = <2>; - ranges; + usb_2: usb@a400000 { + compatible = "qcom,sc8280xp-dwc3-mp", "qcom,snps-dwc3"; + reg = <0 0x0a400000 0 0x10000>; clocks = <&gcc GCC_CFG_NOC_USB3_MP_AXI_CLK>, <&gcc GCC_USB30_MP_MASTER_CLK>, @@ -3480,7 +3477,8 @@ usb_2: usb@a4f8800 { <&gcc GCC_USB30_MP_MASTER_CLK>; assigned-clock-rates = <19200000>, <200000000>; - interrupts-extended = <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&intc GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>, <&intc GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>, <&intc GIC_SPI 857 IRQ_TYPE_LEVEL_HIGH>, <&intc GIC_SPI 856 IRQ_TYPE_LEVEL_HIGH>, @@ -3499,7 +3497,8 @@ usb_2: usb@a4f8800 { <&pdc 16 IRQ_TYPE_LEVEL_HIGH>, <&pdc 17 IRQ_TYPE_LEVEL_HIGH>; - interrupt-names = "pwr_event_1", "pwr_event_2", + interrupt-names = "dwc_usb3", + "pwr_event_1", "pwr_event_2", "pwr_event_3", "pwr_event_4", "hs_phy_1", "hs_phy_2", "hs_phy_3", "hs_phy_4", @@ -3509,6 +3508,7 @@ usb_2: usb@a4f8800 { "dp_hs_phy_4", "dm_hs_phy_4", "ss_phy_1", "ss_phy_2"; + iommus = <&apps_smmu 0x800 0x0>; power-domains = <&gcc USB30_MP_GDSC>; required-opps = <&rpmhpd_opp_nom>; @@ -3518,35 +3518,28 @@ usb_2: usb@a4f8800 { <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_USB3_MP 0>; interconnect-names = "usb-ddr", "apps-usb"; + phys = <&usb_2_hsphy0>, <&usb_2_qmpphy0>, + <&usb_2_hsphy1>, <&usb_2_qmpphy1>, + <&usb_2_hsphy2>, + <&usb_2_hsphy3>; + phy-names = "usb2-0", "usb3-0", + "usb2-1", "usb3-1", + "usb2-2", + "usb2-3"; + wakeup-source; + dr_mode = "host"; + + snps,dis-u1-entry-quirk; + snps,dis-u2-entry-quirk; + status = "disabled"; + }; - usb_2_dwc3: usb@a400000 { - compatible = "snps,dwc3"; - reg = <0 0x0a400000 0 0xcd00>; - interrupts = ; - iommus = <&apps_smmu 0x800 0x0>; - phys = <&usb_2_hsphy0>, <&usb_2_qmpphy0>, - <&usb_2_hsphy1>, <&usb_2_qmpphy1>, - <&usb_2_hsphy2>, - <&usb_2_hsphy3>; - phy-names = "usb2-0", "usb3-0", - "usb2-1", "usb3-1", - "usb2-2", - "usb2-3"; - dr_mode = "host"; - snps,dis-u1-entry-quirk; - snps,dis-u2-entry-quirk; - }; - }; - - usb_0: usb@a6f8800 { - compatible = "qcom,sc8280xp-dwc3", "qcom,dwc3"; - reg = <0 0x0a6f8800 0 0x400>; - #address-cells = <2>; - #size-cells = <2>; - ranges; + usb_0: usb@a600000 { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a600000 0 0x20000>; clocks = <&gcc GCC_CFG_NOC_USB3_PRIM_AXI_CLK>, <&gcc GCC_USB30_PRIM_MASTER_CLK>, @@ -3564,17 +3557,20 @@ usb_0: usb@a6f8800 { <&gcc GCC_USB30_PRIM_MASTER_CLK>; assigned-clock-rates = <19200000>, <200000000>; - interrupts-extended = <&intc GIC_SPI 804 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&intc GIC_SPI 803 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 804 IRQ_TYPE_LEVEL_HIGH>, <&intc GIC_SPI 805 IRQ_TYPE_LEVEL_HIGH>, <&pdc 14 IRQ_TYPE_EDGE_BOTH>, <&pdc 15 IRQ_TYPE_EDGE_BOTH>, <&pdc 138 IRQ_TYPE_LEVEL_HIGH>; - interrupt-names = "pwr_event", + interrupt-names = "dwc_usb3", + "pwr_event", "hs_phy_irq", "dp_hs_phy_irq", "dm_hs_phy_irq", "ss_phy_irq"; + iommus = <&apps_smmu 0x820 0x0>; power-domains = <&gcc USB30_PRIM_GDSC>; required-opps = <&rpmhpd_opp_nom>; @@ -3584,45 +3580,40 @@ usb_0: usb@a6f8800 { <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_USB3_0 0>; interconnect-names = "usb-ddr", "apps-usb"; + phys = <&usb_0_hsphy>, <&usb_0_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", "usb3-phy"; + wakeup-source; - status = "disabled"; + snps,dis-u1-entry-quirk; + snps,dis-u2-entry-quirk; - usb_0_dwc3: usb@a600000 { - compatible = "snps,dwc3"; - reg = <0 0x0a600000 0 0xcd00>; - interrupts = ; - iommus = <&apps_smmu 0x820 0x0>; - phys = <&usb_0_hsphy>, <&usb_0_qmpphy QMP_USB43DP_USB3_PHY>; - phy-names = "usb2-phy", "usb3-phy"; - snps,dis-u1-entry-quirk; - snps,dis-u2-entry-quirk; + status = "disabled"; - ports { - #address-cells = <1>; - #size-cells = <0>; + ports { + #address-cells = <1>; + #size-cells = <0>; - port@0 { - reg = <0>; + port@0 { + reg = <0>; - usb_0_dwc3_hs: endpoint { - }; + usb_0_dwc3_hs: endpoint { }; + }; - port@1 { - reg = <1>; + port@1 { + reg = <1>; - usb_0_dwc3_ss: endpoint { - remote-endpoint = <&usb_0_qmpphy_usb_ss_in>; - }; + usb_0_dwc3_ss: endpoint { + remote-endpoint = <&usb_0_qmpphy_usb_ss_in>; }; }; }; }; - usb_1: usb@a8f8800 { - compatible = "qcom,sc8280xp-dwc3", "qcom,dwc3"; - reg = <0 0x0a8f8800 0 0x400>; + usb_1: usb@a800000 { + compatible = "qcom,sc8280xp-dwc3", "qcom,snps-dwc3"; + reg = <0 0x0a800000 0 0x10000>; #address-cells = <2>; #size-cells = <2>; ranges; @@ -3643,17 +3634,20 @@ usb_1: usb@a8f8800 { <&gcc GCC_USB30_SEC_MASTER_CLK>; assigned-clock-rates = <19200000>, <200000000>; - interrupts-extended = <&intc GIC_SPI 811 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&intc GIC_SPI 810 IRQ_TYPE_LEVEL_HIGH>, + <&intc GIC_SPI 811 IRQ_TYPE_LEVEL_HIGH>, <&intc GIC_SPI 790 IRQ_TYPE_LEVEL_HIGH>, <&pdc 12 IRQ_TYPE_EDGE_BOTH>, <&pdc 13 IRQ_TYPE_EDGE_BOTH>, <&pdc 136 IRQ_TYPE_LEVEL_HIGH>; - interrupt-names = "pwr_event", + interrupt-names = "dwc_usb3", + "pwr_event", "hs_phy_irq", "dp_hs_phy_irq", "dm_hs_phy_irq", "ss_phy_irq"; + iommus = <&apps_smmu 0x860 0x0>; power-domains = <&gcc USB30_SEC_GDSC>; required-opps = <&rpmhpd_opp_nom>; @@ -3663,37 +3657,32 @@ usb_1: usb@a8f8800 { <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_USB3_1 0>; interconnect-names = "usb-ddr", "apps-usb"; + phys = <&usb_1_hsphy>, <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; + phy-names = "usb2-phy", "usb3-phy"; + wakeup-source; - status = "disabled"; + snps,dis-u1-entry-quirk; + snps,dis-u2-entry-quirk; - usb_1_dwc3: usb@a800000 { - compatible = "snps,dwc3"; - reg = <0 0x0a800000 0 0xcd00>; - interrupts = ; - iommus = <&apps_smmu 0x860 0x0>; - phys = <&usb_1_hsphy>, <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; - phy-names = "usb2-phy", "usb3-phy"; - snps,dis-u1-entry-quirk; - snps,dis-u2-entry-quirk; + status = "disabled"; - ports { - #address-cells = <1>; - #size-cells = <0>; + ports { + #address-cells = <1>; + #size-cells = <0>; - port@0 { - reg = <0>; + port@0 { + reg = <0>; - usb_1_dwc3_hs: endpoint { - }; + usb_1_dwc3_hs: endpoint { }; + }; - port@1 { - reg = <1>; + port@1 { + reg = <1>; - usb_1_dwc3_ss: endpoint { - remote-endpoint = <&usb_1_qmpphy_usb_ss_in>; - }; + usb_1_dwc3_ss: endpoint { + remote-endpoint = <&usb_1_qmpphy_usb_ss_in>; }; }; };