mirror of https://gitee.com/openkylin/linux.git
ARM: sun6i: a31s: primo81: Change USB OTG to OTG mode
Now that we have support for the AXP221 PMIC's USB VBUS detection and DRIVEVBUS vbus control, we can use the USB OTG port in proper OTG mode. This patch enables the aforementioned PMIC functions, adds the OTG ID detection pin to the USB PHY node, and changes the mode of USB OTG to "otg". Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
This commit is contained in:
parent
0e9d528f07
commit
723ca929a5
|
@ -158,6 +158,7 @@ axp22x: pmic@68 {
|
|||
reg = <0x68>;
|
||||
interrupt-parent = <&nmi_intc>;
|
||||
interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
|
||||
x-powers,drive-vbus-en;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -226,6 +227,11 @@ ®_dldo3 {
|
|||
regulator-name = "vddio-csi";
|
||||
};
|
||||
|
||||
®_drivevbus {
|
||||
regulator-name = "usb0-vbus";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
®_eldo3 {
|
||||
regulator-min-microvolt = <1080000>;
|
||||
regulator-max-microvolt = <1320000>;
|
||||
|
@ -238,12 +244,18 @@ &simplefb_lcd {
|
|||
};
|
||||
|
||||
&usb_otg {
|
||||
/* otg support requires support for AXP221 usb-power-supply and GPIO */
|
||||
dr_mode = "host";
|
||||
dr_mode = "otg";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb_power_supply {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbphy {
|
||||
usb0_id_det-gpio = <&pio 0 15 GPIO_ACTIVE_HIGH>; /* PA15 */
|
||||
usb0_vbus_power-supply = <&usb_power_supply>;
|
||||
usb0_vbus-supply = <®_drivevbus>;
|
||||
usb1_vbus-supply = <®_dldo1>;
|
||||
status = "okay";
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue