Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: GPL-2.0
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/phy/allwinner,sun5i-a13-usb-phy.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: Allwinner A13 USB PHY Device Tree Bindings
0008 
0009 maintainers:
0010   - Chen-Yu Tsai <wens@csie.org>
0011   - Maxime Ripard <mripard@kernel.org>
0012 
0013 properties:
0014   "#phy-cells":
0015     const: 1
0016 
0017   compatible:
0018     const: allwinner,sun5i-a13-usb-phy
0019 
0020   reg:
0021     items:
0022       - description: PHY Control registers
0023       - description: PHY PMU1 registers
0024 
0025   reg-names:
0026     items:
0027       - const: phy_ctrl
0028       - const: pmu1
0029 
0030   clocks:
0031     maxItems: 1
0032     description: USB OTG PHY bus clock
0033 
0034   clock-names:
0035     const: usb_phy
0036 
0037   resets:
0038     items:
0039       - description: USB OTG reset
0040       - description: USB Host 1 Controller reset
0041 
0042   reset-names:
0043     items:
0044       - const: usb0_reset
0045       - const: usb1_reset
0046 
0047   usb0_id_det-gpios:
0048     maxItems: 1
0049     description: GPIO to the USB OTG ID pin
0050 
0051   usb0_vbus_det-gpios:
0052     maxItems: 1
0053     description: GPIO to the USB OTG VBUS detect pin
0054 
0055   usb0_vbus_power-supply:
0056     description: Power supply to detect the USB OTG VBUS
0057 
0058   usb0_vbus-supply:
0059     description: Regulator controlling USB OTG VBUS
0060 
0061   usb1_vbus-supply:
0062     description: Regulator controlling USB1 Host controller
0063 
0064 required:
0065   - "#phy-cells"
0066   - compatible
0067   - clocks
0068   - clock-names
0069   - reg
0070   - reg-names
0071   - resets
0072   - reset-names
0073 
0074 additionalProperties: false
0075 
0076 examples:
0077   - |
0078     #include <dt-bindings/gpio/gpio.h>
0079     #include <dt-bindings/clock/sun5i-ccu.h>
0080     #include <dt-bindings/reset/sun5i-ccu.h>
0081 
0082     phy@1c13400 {
0083         #phy-cells = <1>;
0084         compatible = "allwinner,sun5i-a13-usb-phy";
0085         reg = <0x01c13400 0x10>, <0x01c14800 0x4>;
0086         reg-names = "phy_ctrl", "pmu1";
0087         clocks = <&ccu CLK_USB_PHY0>;
0088         clock-names = "usb_phy";
0089         resets = <&ccu RST_USB_PHY0>, <&ccu RST_USB_PHY1>;
0090         reset-names = "usb0_reset", "usb1_reset";
0091         usb0_id_det-gpios = <&pio 6 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PG2 */
0092         usb0_vbus_det-gpios = <&pio 6 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PG1 */
0093         usb0_vbus-supply = <&reg_usb0_vbus>;
0094         usb1_vbus-supply = <&reg_usb1_vbus>;
0095     };