treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / Documentation / devicetree / bindings / usb / dwc2.yaml
blob71cf7ba32237613b8caf72cc83a51e8c34af0890
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#
7 title: DesignWare HS OTG USB 2.0 controller Bindings
9 maintainers:
10   - Rob Herring <robh@kernel.org>
12 properties:
13   compatible:
14     oneOf:
15       - const: brcm,bcm2835-usb
16       - const: hisilicon,hi6220-usb
17       - items:
18           - const: rockchip,rk3066-usb
19           - const: snps,dwc2
20       - items:
21           - const: rockchip,px30-usb
22           - const: rockchip,rk3066-usb
23           - const: snps,dwc2
24       - items:
25           - const: rockchip,rk3036-usb
26           - const: rockchip,rk3066-usb
27           - const: snps,dwc2
28       - items:
29           - const: rockchip,rv1108-usb
30           - const: rockchip,rk3066-usb
31           - const: snps,dwc2
32       - items:
33           - const: rockchip,rk3188-usb
34           - const: rockchip,rk3066-usb
35           - const: snps,dwc2
36       - items:
37           - const: rockchip,rk3228-usb
38           - const: rockchip,rk3066-usb
39           - const: snps,dwc2
40       - items:
41           - const: rockchip,rk3288-usb
42           - const: rockchip,rk3066-usb
43           - const: snps,dwc2
44       - const: lantiq,arx100-usb
45       - const: lantiq,xrx200-usb
46       - items:
47           - const: amlogic,meson8-usb
48           - const: snps,dwc2
49       - items:
50           - const: amlogic,meson8b-usb
51           - const: snps,dwc2
52       - const: amlogic,meson-gxbb-usb
53       - items:
54           - const: amlogic,meson-g12a-usb
55           - const: snps,dwc2
56       - const: amcc,dwc-otg
57       - const: snps,dwc2
58       - const: st,stm32f4x9-fsotg
59       - const: st,stm32f4x9-hsotg
60       - const: st,stm32f7-hsotg
61       - const: samsung,s3c6400-hsotg
63   reg:
64     maxItems: 1
66   interrupts:
67     maxItems: 1
69   clocks:
70     maxItems: 1
72   clock-names:
73     items:
74       - const: otg
76   resets:
77     items:
78      - description: common reset
79      - description: ecc reset
80     minItems: 1
82   reset-names:
83     items:
84      - const: dwc2
85      - const: dwc2-ecc
86     minItems: 1
88   phys:
89     maxItems: 1
91   phy-names:
92     const: usb2-phy
94   vbus-supply:
95     description: reference to the VBUS regulator. Depending on the current mode
96       this is enabled (in "host" mode") or disabled (in "peripheral" mode). The
97       regulator is updated if the controller is configured in "otg" mode and the
98       status changes between "host" and "peripheral".
100   vusb_d-supply:
101     description: phandle to voltage regulator of digital section,
103   vusb_a-supply:
104     description: phandle to voltage regulator of analog section.
106   dr_mode:
107     enum: [host, peripheral, otg]
109   g-rx-fifo-size:
110     $ref: /schemas/types.yaml#/definitions/uint32
111     description: size of rx fifo size in gadget mode.
113   g-np-tx-fifo-size:
114     $ref: /schemas/types.yaml#/definitions/uint32
115     description: size of non-periodic tx fifo size in gadget mode.
117   g-tx-fifo-size:
118     $ref: /schemas/types.yaml#/definitions/uint32-array
119     description: size of periodic tx fifo per endpoint (except ep0) in gadget mode.
121   snps,need-phy-for-wake:
122     $ref: /schemas/types.yaml#/definitions/flag
123     description: If present indicates that the phy needs to be left on for remote wakeup during suspend.
125   snps,reset-phy-on-wake:
126     $ref: /schemas/types.yaml#/definitions/flag
127     description: If present indicates that we need to reset the PHY when we detect a wakeup.
128                  This is due to a hardware errata.
130 required:
131   - compatible
132   - reg
133   - interrupts
134   - clocks
135   - clock-names
137 additionalProperties: false
139 examples:
140   - |
141       usb@101c0000 {
142         compatible = "rockchip,rk3066-usb", "snps,dwc2";
143         reg = <0x10180000 0x40000>;
144         interrupts = <18>;
145         clocks = <&usb_otg_ahb_clk>;
146         clock-names = "otg";
147         phys = <&usbphy>;
148         phy-names = "usb2-phy";
149       };