Commit c2147cbf authored by Yoshihiro Shimoda's avatar Yoshihiro Shimoda Committed by Greg Kroah-Hartman

usb: gadget: udc: renesas-usb3: clear VBOUT bit in DRD_CON

commit b2f1eaae upstream.

This driver should clear the bit. Otherwise, the VBUS will output
wrongly if the usb port on a board has VBUS output capability.

Fixes: 746bfe63 ("usb: gadget: renesas_usb3: add support for
		      Renesas USB3.0 peripheral controller")
Signed-off-by: default avatarYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 635d409e
...@@ -106,6 +106,7 @@ ...@@ -106,6 +106,7 @@
/* DRD_CON */ /* DRD_CON */
#define DRD_CON_PERI_CON BIT(24) #define DRD_CON_PERI_CON BIT(24)
#define DRD_CON_VBOUT BIT(0)
/* USB_INT_ENA_1 and USB_INT_STA_1 */ /* USB_INT_ENA_1 and USB_INT_STA_1 */
#define USB_INT_1_B3_PLLWKUP BIT(31) #define USB_INT_1_B3_PLLWKUP BIT(31)
...@@ -363,6 +364,7 @@ static void usb3_init_epc_registers(struct renesas_usb3 *usb3) ...@@ -363,6 +364,7 @@ static void usb3_init_epc_registers(struct renesas_usb3 *usb3)
{ {
/* FIXME: How to change host / peripheral mode as well? */ /* FIXME: How to change host / peripheral mode as well? */
usb3_set_bit(usb3, DRD_CON_PERI_CON, USB3_DRD_CON); usb3_set_bit(usb3, DRD_CON_PERI_CON, USB3_DRD_CON);
usb3_clear_bit(usb3, DRD_CON_VBOUT, USB3_DRD_CON);
usb3_write(usb3, ~0, USB3_USB_INT_STA_1); usb3_write(usb3, ~0, USB3_USB_INT_STA_1);
usb3_enable_irq_1(usb3, USB_INT_1_VBUS_CNG); usb3_enable_irq_1(usb3, USB_INT_1_VBUS_CNG);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment