1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0 2c66ec88fSEmmanuel Vadot%YAML 1.2 3c66ec88fSEmmanuel Vadot--- 4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/phy/allwinner,sun4i-a10-usb-phy.yaml# 5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6c66ec88fSEmmanuel Vadot 7*7ef62cebSEmmanuel Vadottitle: Allwinner A10 USB PHY 8c66ec88fSEmmanuel Vadot 9c66ec88fSEmmanuel Vadotmaintainers: 10c66ec88fSEmmanuel Vadot - Chen-Yu Tsai <wens@csie.org> 11c66ec88fSEmmanuel Vadot - Maxime Ripard <mripard@kernel.org> 12c66ec88fSEmmanuel Vadot 13c66ec88fSEmmanuel Vadotproperties: 14c66ec88fSEmmanuel Vadot "#phy-cells": 15c66ec88fSEmmanuel Vadot const: 1 16c66ec88fSEmmanuel Vadot 17c66ec88fSEmmanuel Vadot compatible: 18c66ec88fSEmmanuel Vadot enum: 19c66ec88fSEmmanuel Vadot - allwinner,sun4i-a10-usb-phy 20c66ec88fSEmmanuel Vadot - allwinner,sun7i-a20-usb-phy 21c66ec88fSEmmanuel Vadot 22c66ec88fSEmmanuel Vadot reg: 23c66ec88fSEmmanuel Vadot items: 24c66ec88fSEmmanuel Vadot - description: PHY Control registers 25c66ec88fSEmmanuel Vadot - description: PHY PMU1 registers 26c66ec88fSEmmanuel Vadot - description: PHY PMU2 registers 27c66ec88fSEmmanuel Vadot 28c66ec88fSEmmanuel Vadot reg-names: 29c66ec88fSEmmanuel Vadot items: 30c66ec88fSEmmanuel Vadot - const: phy_ctrl 31c66ec88fSEmmanuel Vadot - const: pmu1 32c66ec88fSEmmanuel Vadot - const: pmu2 33c66ec88fSEmmanuel Vadot 34c66ec88fSEmmanuel Vadot clocks: 35c66ec88fSEmmanuel Vadot maxItems: 1 36c66ec88fSEmmanuel Vadot description: USB PHY bus clock 37c66ec88fSEmmanuel Vadot 38c66ec88fSEmmanuel Vadot clock-names: 39c66ec88fSEmmanuel Vadot const: usb_phy 40c66ec88fSEmmanuel Vadot 41c66ec88fSEmmanuel Vadot resets: 42c66ec88fSEmmanuel Vadot items: 43c66ec88fSEmmanuel Vadot - description: USB OTG reset 44c66ec88fSEmmanuel Vadot - description: USB Host 1 Controller reset 45c66ec88fSEmmanuel Vadot - description: USB Host 2 Controller reset 46c66ec88fSEmmanuel Vadot 47c66ec88fSEmmanuel Vadot reset-names: 48c66ec88fSEmmanuel Vadot items: 49c66ec88fSEmmanuel Vadot - const: usb0_reset 50c66ec88fSEmmanuel Vadot - const: usb1_reset 51c66ec88fSEmmanuel Vadot - const: usb2_reset 52c66ec88fSEmmanuel Vadot 53c66ec88fSEmmanuel Vadot usb0_id_det-gpios: 545def4c47SEmmanuel Vadot maxItems: 1 55c66ec88fSEmmanuel Vadot description: GPIO to the USB OTG ID pin 56c66ec88fSEmmanuel Vadot 57c66ec88fSEmmanuel Vadot usb0_vbus_det-gpios: 585def4c47SEmmanuel Vadot maxItems: 1 59c66ec88fSEmmanuel Vadot description: GPIO to the USB OTG VBUS detect pin 60c66ec88fSEmmanuel Vadot 61c66ec88fSEmmanuel Vadot usb0_vbus_power-supply: 62c66ec88fSEmmanuel Vadot description: Power supply to detect the USB OTG VBUS 63c66ec88fSEmmanuel Vadot 64c66ec88fSEmmanuel Vadot usb0_vbus-supply: 65c66ec88fSEmmanuel Vadot description: Regulator controlling USB OTG VBUS 66c66ec88fSEmmanuel Vadot 67c66ec88fSEmmanuel Vadot usb1_vbus-supply: 68c66ec88fSEmmanuel Vadot description: Regulator controlling USB1 Host controller 69c66ec88fSEmmanuel Vadot 70c66ec88fSEmmanuel Vadot usb2_vbus-supply: 71c66ec88fSEmmanuel Vadot description: Regulator controlling USB2 Host controller 72c66ec88fSEmmanuel Vadot 73c66ec88fSEmmanuel Vadotrequired: 74c66ec88fSEmmanuel Vadot - "#phy-cells" 75c66ec88fSEmmanuel Vadot - compatible 76c66ec88fSEmmanuel Vadot - clocks 77c66ec88fSEmmanuel Vadot - clock-names 78c66ec88fSEmmanuel Vadot - reg 79c66ec88fSEmmanuel Vadot - reg-names 80c66ec88fSEmmanuel Vadot - resets 81c66ec88fSEmmanuel Vadot - reset-names 82c66ec88fSEmmanuel Vadot 83c66ec88fSEmmanuel VadotadditionalProperties: false 84c66ec88fSEmmanuel Vadot 85c66ec88fSEmmanuel Vadotexamples: 86c66ec88fSEmmanuel Vadot - | 87c66ec88fSEmmanuel Vadot #include <dt-bindings/gpio/gpio.h> 88c66ec88fSEmmanuel Vadot #include <dt-bindings/clock/sun4i-a10-ccu.h> 89c66ec88fSEmmanuel Vadot #include <dt-bindings/reset/sun4i-a10-ccu.h> 90c66ec88fSEmmanuel Vadot 91c66ec88fSEmmanuel Vadot usbphy: phy@1c13400 { 92c66ec88fSEmmanuel Vadot #phy-cells = <1>; 93c66ec88fSEmmanuel Vadot compatible = "allwinner,sun4i-a10-usb-phy"; 94c66ec88fSEmmanuel Vadot reg = <0x01c13400 0x10>, <0x01c14800 0x4>, <0x01c1c800 0x4>; 95c66ec88fSEmmanuel Vadot reg-names = "phy_ctrl", "pmu1", "pmu2"; 96c66ec88fSEmmanuel Vadot clocks = <&ccu CLK_USB_PHY>; 97c66ec88fSEmmanuel Vadot clock-names = "usb_phy"; 98c66ec88fSEmmanuel Vadot resets = <&ccu RST_USB_PHY0>, 99c66ec88fSEmmanuel Vadot <&ccu RST_USB_PHY1>, 100c66ec88fSEmmanuel Vadot <&ccu RST_USB_PHY2>; 101c66ec88fSEmmanuel Vadot reset-names = "usb0_reset", "usb1_reset", "usb2_reset"; 102c66ec88fSEmmanuel Vadot usb0_id_det-gpios = <&pio 7 19 GPIO_ACTIVE_HIGH>; 103c66ec88fSEmmanuel Vadot usb0_vbus_det-gpios = <&pio 7 22 GPIO_ACTIVE_HIGH>; 104c66ec88fSEmmanuel Vadot usb0_vbus-supply = <®_usb0_vbus>; 105c66ec88fSEmmanuel Vadot usb1_vbus-supply = <®_usb1_vbus>; 106c66ec88fSEmmanuel Vadot usb2_vbus-supply = <®_usb2_vbus>; 107c66ec88fSEmmanuel Vadot }; 108