usb: dwc_otg_310: fix usb vbus power controlled by pmic
On rockchip platforms, usb vbus 5V can be controlled by
gpio or pmic while otg work as host mode. If vbus 5v is
supplied from pmic, and usb charger circuit also connect
to pmic, we need to ensure usb vbus is disconnected from
external power source (e.g. PC or USB adapter) before
power on vbus 5v from pmic, otherwise, the pmic may be
broken by the external power. It always happens with rk816
which support usb charge and usb vbus power function.
With this patch, if we use pmic for usb vbus 5v, it needs
to add a new property 'rockchip,usb-pmic-vbus' in dts usb
node, like this:
&usb0 {
rockchip,usb-pmic-vbus;
};
Change-Id: I1055f637e77fb5dd681994ff440293a6682b2a12
Signed-off-by: William Wu <wulf@rock-chips.com>