diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2019-07-26 06:59:03 +0200 |
---|---|---|
committer | Felipe Balbi <felipe.balbi@linux.intel.com> | 2019-08-12 07:55:24 +0200 |
commit | 602fda17c7356bb7ae98467d93549057481d11dd (patch) | |
tree | 0e17f55cfee73041806a4017d47ffe93700f4eac /drivers/usb/gadget | |
parent | usb: gadget: udc: renesas_usb3: Fix sysfs interface of "role" (diff) | |
download | linux-602fda17c7356bb7ae98467d93549057481d11dd.tar.xz linux-602fda17c7356bb7ae98467d93549057481d11dd.zip |
usb: gadget: composite: Clear "suspended" on reset/disconnect
In some cases, one can get out of suspend with a reset or
a disconnect followed by a reconnect. Previously we would
leave a stale suspended flag set.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r-- | drivers/usb/gadget/composite.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/gadget/composite.c b/drivers/usb/gadget/composite.c index 9118b42c70b6..76883ff4f5bb 100644 --- a/drivers/usb/gadget/composite.c +++ b/drivers/usb/gadget/composite.c @@ -1976,6 +1976,7 @@ void composite_disconnect(struct usb_gadget *gadget) * disconnect callbacks? */ spin_lock_irqsave(&cdev->lock, flags); + cdev->suspended = 0; if (cdev->config) reset_config(cdev); if (cdev->driver->disconnect) |