xref: /freebsd/sys/contrib/device-tree/Bindings/usb/dwc2.yaml (revision 59c8e88e72633afbc47a4ace0d2170d00d51f7dc)
1# SPDX-License-Identifier: GPL-2.0
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/usb/dwc2.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: DesignWare HS OTG USB 2.0 controller
8
9maintainers:
10  - Rob Herring <robh@kernel.org>
11
12allOf:
13  - $ref: usb-drd.yaml#
14  - $ref: usb-hcd.yaml#
15
16properties:
17  compatible:
18    oneOf:
19      - const: brcm,bcm2835-usb
20      - const: hisilicon,hi6220-usb
21      - const: ingenic,jz4775-otg
22      - const: ingenic,jz4780-otg
23      - const: ingenic,x1000-otg
24      - const: ingenic,x1600-otg
25      - const: ingenic,x1700-otg
26      - const: ingenic,x1830-otg
27      - const: ingenic,x2000-otg
28      - items:
29          - const: rockchip,rk3066-usb
30          - const: snps,dwc2
31      - items:
32          - enum:
33              - rockchip,px30-usb
34              - rockchip,rk3036-usb
35              - rockchip,rk3128-usb
36              - rockchip,rk3188-usb
37              - rockchip,rk3228-usb
38              - rockchip,rk3288-usb
39              - rockchip,rk3308-usb
40              - rockchip,rk3328-usb
41              - rockchip,rk3368-usb
42              - rockchip,rv1108-usb
43          - const: rockchip,rk3066-usb
44          - const: snps,dwc2
45      - const: lantiq,arx100-usb
46      - const: lantiq,ase-usb
47      - const: lantiq,danube-usb
48      - const: lantiq,xrx200-usb
49      - const: lantiq,xrx300-usb
50      - items:
51          - enum:
52              - amlogic,meson8-usb
53              - amlogic,meson8b-usb
54              - amlogic,meson-gxbb-usb
55              - amlogic,meson-g12a-usb
56              - intel,socfpga-agilex-hsotg
57          - const: snps,dwc2
58      - const: amcc,dwc-otg
59      - const: apm,apm82181-dwc-otg
60      - const: snps,dwc2
61      - const: st,stm32f4x9-fsotg
62      - const: st,stm32f4x9-hsotg
63      - const: st,stm32f7-hsotg
64      - const: st,stm32mp15-fsotg
65      - items:
66          - const: st,stm32mp15-hsotg
67          - const: snps,dwc2
68      - const: samsung,s3c6400-hsotg
69      - const: intel,socfpga-agilex-hsotg
70
71  reg:
72    maxItems: 1
73
74  interrupts:
75    maxItems: 1
76
77  clocks:
78    minItems: 1
79    maxItems: 2
80
81  clock-names:
82    items:
83      - const: otg
84      - const: utmi
85    minItems: 1
86
87  disable-over-current:
88    type: boolean
89    description: whether to disable detection of over-current condition.
90
91  iommus:
92    maxItems: 1
93
94  resets:
95    items:
96      - description: common reset
97      - description: ecc reset
98    minItems: 1
99
100  reset-names:
101    items:
102      - const: dwc2
103      - const: dwc2-ecc
104    minItems: 1
105
106  phys:
107    maxItems: 1
108
109  phy-names:
110    const: usb2-phy
111
112  power-domains:
113    maxItems: 1
114
115  vbus-supply:
116    description: reference to the VBUS regulator. Depending on the current mode
117      this is enabled (in "host" mode") or disabled (in "peripheral" mode). The
118      regulator is updated if the controller is configured in "otg" mode and the
119      status changes between "host" and "peripheral".
120
121  vusb_d-supply:
122    description: phandle to voltage regulator of digital section,
123
124  vusb_a-supply:
125    description: phandle to voltage regulator of analog section.
126
127  usb33d-supply:
128    description: reference to the VBUS and ID sensing comparators supply, in
129      order to perform OTG operation, used on STM32MP15 SoCs.
130
131  dr_mode: true
132
133  otg-rev: true
134
135  hnp-disable: true
136
137  srp-disable: true
138
139  usb-role-switch: true
140
141  role-switch-default-mode: true
142
143  g-rx-fifo-size:
144    $ref: /schemas/types.yaml#/definitions/uint32
145    description: size of rx fifo size in gadget mode.
146
147  g-np-tx-fifo-size:
148    $ref: /schemas/types.yaml#/definitions/uint32
149    description: size of non-periodic tx fifo size in gadget mode.
150
151  g-tx-fifo-size:
152    $ref: /schemas/types.yaml#/definitions/uint32-array
153    description: size of periodic tx fifo per endpoint (except ep0) in gadget mode.
154
155  snps,need-phy-for-wake:
156    $ref: /schemas/types.yaml#/definitions/flag
157    description: If present indicates that the phy needs to be left on for
158      remote wakeup during suspend.
159
160  snps,reset-phy-on-wake:
161    $ref: /schemas/types.yaml#/definitions/flag
162    description: If present indicates that we need to reset the PHY when we
163      detect a wakeup. This is due to a hardware errata.
164
165  port:
166    description:
167      Any connector to the data bus of this controller should be modelled
168      using the OF graph bindings specified, if the "usb-role-switch"
169      property is used.
170    $ref: /schemas/graph.yaml#/properties/port
171
172  tpl-support: true
173
174dependencies:
175  port: [ usb-role-switch ]
176  role-switch-default-mode: [ usb-role-switch ]
177
178required:
179  - compatible
180  - reg
181  - interrupts
182  - clocks
183  - clock-names
184
185additionalProperties: false
186
187examples:
188  - |
189      usb@101c0000 {
190        compatible = "rockchip,rk3066-usb", "snps,dwc2";
191        reg = <0x10180000 0x40000>;
192        interrupts = <18>;
193        clocks = <&usb_otg_ahb_clk>;
194        clock-names = "otg";
195        phys = <&usbphy>;
196        phy-names = "usb2-phy";
197      };
198
199...
200