Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

usb: phy: nop: device tree documentation for vbus

Enhance the phy documentation by adding 2 new optional bindings :
- the vbus gpio, which detects usb insertion
- the vbus regulator, which provides current drawn from the usb cable

Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Felipe Balbi <balbi@ti.com>

authored by

Robert Jarzmik and committed by
Felipe Balbi
7bdea87a e9f2cefb

+8
+8
Documentation/devicetree/bindings/usb/usb-nop-xceiv.txt
··· 17 17 18 18 - reset-gpios: Should specify the GPIO for reset. 19 19 20 + - vbus-detect-gpio: should specify the GPIO detecting a VBus insertion 21 + (see Documentation/devicetree/bindings/gpio/gpio.txt) 22 + - vbus-regulator : should specifiy the regulator supplying current drawn from 23 + the VBus line (see Documentation/devicetree/bindings/regulator/regulator.txt). 24 + 20 25 Example: 21 26 22 27 hsusb1_phy { ··· 31 26 clock-names = "main_clk"; 32 27 vcc-supply = <&hsusb1_vcc_regulator>; 33 28 reset-gpios = <&gpio1 7 GPIO_ACTIVE_LOW>; 29 + vbus-detect-gpio = <&gpio2 13 GPIO_ACTIVE_HIGH>; 30 + vbus-regulator = <&vbus_regulator>; 34 31 }; 35 32 36 33 hsusb1_phy is a NOP USB PHY device that gets its clock from an oscillator 37 34 and expects that clock to be configured to 19.2MHz by the NOP PHY driver. 38 35 hsusb1_vcc_regulator provides power to the PHY and GPIO 7 controls RESET. 36 + GPIO 13 detects VBus insertion, and accordingly notifies the vbus-regulator.