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