Skip to content

Commit

Permalink
usb: renesas_usbhs: fixup signal the driver that cable was disconnected
Browse files Browse the repository at this point in the history
current renesas_usbhs is using new style udc_start/stop from
af1d705
(usb: gadget: renesas: convert to new style).

cable disconnected signal was needed.
This patch fixup it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Kuninori Morimoto authored and Greg Kroah-Hartman committed Nov 29, 2011
1 parent f8eff0a commit 8885a89
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions drivers/usb/renesas_usbhs/mod_gadget.c
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,13 @@ static int usbhsg_start(struct usbhs_priv *priv)

static int usbhsg_stop(struct usbhs_priv *priv)
{
struct usbhsg_gpriv *gpriv = usbhsg_priv_to_gpriv(priv);

/* cable disconnect */
if (gpriv->driver &&
gpriv->driver->disconnect)
gpriv->driver->disconnect(&gpriv->gadget);

return usbhsg_try_stop(priv, USBHSG_STATUS_STARTED);
}

Expand Down

0 comments on commit 8885a89

Please sign in to comment.