FILE
mediatek,mtk-xhci.yaml
File preview with syntax highlighting.
linux-6.19.14/Documentation/devicetree/bindings/usb/mediatek,mtk-xhci.yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2# Copyright (c) 2020 MediaTek 3%YAML 1.2 4--- 5$id: http://devicetree.org/schemas/usb/mediatek,mtk-xhci.yaml# 6$schema: http://devicetree.org/meta-schemas/core.yaml# 7 8title: MediaTek USB3 xHCI 9 10maintainers: 11 - Chunfeng Yun <chunfeng.yun@mediatek.com> 12 13allOf: 14 - $ref: usb-xhci.yaml 15 16description: | 17 There are two scenarios: 18 case 1: only supports xHCI driver; 19 case 2: supports dual-role mode, and the host is based on xHCI driver. 20 21properties: 22 # common properties for both case 1 and case 2 23 compatible: 24 items: 25 - enum: 26 - mediatek,mt2701-xhci 27 - mediatek,mt2712-xhci 28 - mediatek,mt7622-xhci 29 - mediatek,mt7623-xhci 30 - mediatek,mt7629-xhci 31 - mediatek,mt7986-xhci 32 - mediatek,mt7988-xhci 33 - mediatek,mt8173-xhci 34 - mediatek,mt8183-xhci 35 - mediatek,mt8186-xhci 36 - mediatek,mt8188-xhci 37 - mediatek,mt8189-xhci 38 - mediatek,mt8192-xhci 39 - mediatek,mt8195-xhci 40 - mediatek,mt8365-xhci 41 - const: mediatek,mtk-xhci 42 43 reg: 44 minItems: 1 45 items: 46 - description: the registers of xHCI MAC 47 - description: the registers of IP Port Control 48 49 reg-names: 50 minItems: 1 51 items: 52 - const: mac 53 - const: ippc # optional, only needed for case 1. 54 55 interrupts: 56 description: 57 use "interrupts-extended" when the interrupts are connected to the 58 separate interrupt controllers 59 minItems: 1 60 items: 61 - description: xHCI host controller interrupt 62 - description: optional, wakeup interrupt used to support runtime PM 63 64 interrupt-names: 65 minItems: 1 66 items: 67 - const: host 68 - const: wakeup 69 70 power-domains: 71 description: A phandle to USB power domain node to control USB's MTCMOS 72 maxItems: 1 73 74 clocks: 75 minItems: 1 76 items: 77 - description: Controller clock used by normal mode 78 - description: Reference clock used by low power mode etc 79 - description: Mcu bus clock for register access 80 - description: DMA bus clock for data transfer 81 - description: controller clock 82 - description: frame count clock 83 84 clock-names: 85 minItems: 1 86 items: 87 - const: sys_ck # required, the following ones are optional 88 - const: ref_ck 89 - const: mcu_ck 90 - const: dma_ck 91 - const: xhci_ck 92 - const: frmcnt_ck 93 94 phys: 95 description: 96 List of all PHYs used on this HCD, it's better to keep PHYs in order 97 as the hardware layout 98 minItems: 1 99 items: 100 - description: USB2/HS PHY # required, others are optional 101 - description: USB3/SS(P) PHY 102 - description: USB2/HS PHY 103 - description: USB3/SS(P) PHY 104 - description: USB2/HS PHY 105 - description: USB3/SS(P) PHY 106 - description: USB2/HS PHY 107 - description: USB3/SS(P) PHY 108 - description: USB2/HS PHY 109 110 port: 111 $ref: /schemas/graph.yaml#/properties/port 112 description: Super Speed (SS) Output endpoint to a Type-C connector 113 114 vusb33-supply: 115 description: Regulator of USB AVDD3.3v 116 117 vbus-supply: 118 description: Regulator of USB VBUS5v 119 120 resets: 121 maxItems: 1 122 123 usb3-lpm-capable: true 124 125 usb2-lpm-disable: true 126 127 imod-interval-ns: 128 description: 129 Interrupt moderation interval value, it is 8 times as much as that 130 defined in the xHCI spec on MTK's controller. 131 default: 5000 132 133 rx-fifo-depth: 134 $ref: /schemas/types.yaml#/definitions/uint32 135 description: 136 It is a quirk used to work around Gen1 isoc-in endpoint transfer issue 137 that still send out unexpected ACK after device finishes the burst 138 transfer with a short packet and cause an exception, specially on a 4K 139 camera device, it happens on controller before about IPM v1.6.0; 140 the side-effect is that it may cause performance drop about 10%, 141 including bulk transfer, prefer to use 3k here. The size is in bytes. 142 enum: [1024, 2048, 3072, 4096] 143 144 # the following properties are only used for case 1 145 wakeup-source: 146 description: enable USB remote wakeup, see power/wakeup-source.txt 147 type: boolean 148 149 mediatek,syscon-wakeup: 150 $ref: /schemas/types.yaml#/definitions/phandle-array 151 maxItems: 1 152 description: 153 A phandle to syscon used to access the register of the USB wakeup glue 154 layer between xHCI and SPM, the field should always be 3 cells long. 155 items: 156 items: 157 - description: 158 The first cell represents a phandle to syscon 159 - description: 160 The second cell represents the register base address of the glue 161 layer in syscon 162 - description: | 163 The third cell represents the hardware version of the glue layer, 164 1 - used by mt8173 etc, revision 1 without following IPM rule; 165 2 - used by mt2712 etc, revision 2 following IPM rule; 166 101 - used by mt8183, specific 1.01; 167 102 - used by mt8192, specific 1.02; 168 103 - used by mt8195, IP0, specific 1.03; 169 104 - used by mt8195, IP1, specific 1.04; 170 105 - used by mt8195, IP2, specific 1.05; 171 106 - used by mt8195, IP3, specific 1.06; 172 110 - used by mt8189, IP4, specific 1.10; 173 enum: [1, 2, 101, 102, 103, 104, 105, 106, 110] 174 175 mediatek,u3p-dis-msk: 176 $ref: /schemas/types.yaml#/definitions/uint32 177 description: The mask to disable u3ports, bit0 for u3port0, 178 bit1 for u3port1, ... etc 179 180 mediatek,u2p-dis-msk: 181 $ref: /schemas/types.yaml#/definitions/uint32 182 description: The mask to disable u2ports, bit0 for u2port0, 183 bit1 for u2port1, ... etc 184 185 "#address-cells": 186 const: 1 187 188 "#size-cells": 189 const: 0 190 191patternProperties: 192 "@[0-9a-f]{1}$": 193 type: object 194 description: The hard wired USB devices. 195 196dependencies: 197 wakeup-source: [ 'mediatek,syscon-wakeup' ] 198 199required: 200 - compatible 201 - reg 202 - reg-names 203 - interrupts 204 - clocks 205 - clock-names 206 207additionalProperties: false 208 209examples: 210 - | 211 #include <dt-bindings/clock/mt8173-clk.h> 212 #include <dt-bindings/interrupt-controller/arm-gic.h> 213 #include <dt-bindings/interrupt-controller/irq.h> 214 #include <dt-bindings/phy/phy.h> 215 #include <dt-bindings/power/mt8173-power.h> 216 217 usb@11270000 { 218 compatible = "mediatek,mt8173-xhci", "mediatek,mtk-xhci"; 219 reg = <0x11270000 0x1000>, <0x11280700 0x0100>; 220 reg-names = "mac", "ippc"; 221 interrupts = <GIC_SPI 115 IRQ_TYPE_LEVEL_LOW>; 222 power-domains = <&scpsys MT8173_POWER_DOMAIN_USB>; 223 clocks = <&topckgen CLK_TOP_USB30_SEL>, <&clk26m>; 224 clock-names = "sys_ck", "ref_ck"; 225 phys = <&u3port0 PHY_TYPE_USB3>, <&u2port1 PHY_TYPE_USB2>; 226 vusb33-supply = <&mt6397_vusb_reg>; 227 vbus-supply = <&usb_p1_vbus>; 228 imod-interval-ns = <10000>; 229 mediatek,syscon-wakeup = <&pericfg 0x400 1>; 230 wakeup-source; 231 usb3-lpm-capable; 232 }; 233...
~/
Read-only file preview.