diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2019-07-26 07:59:03 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-09-06 11:21:57 +0300 |
commit | 122ab8ea641cd7752290d2c0179a6e8b42c48d8a (patch) | |
tree | e37960ce37d0ac4920f8dd3a9ceebd3302c9c8a0 /drivers/usb/gadget | |
parent | 21ec20f62fae40d39ac2076e57d190b155ad27b0 (diff) | |
download | linux-122ab8ea641cd7752290d2c0179a6e8b42c48d8a.tar.xz |
usb: gadget: composite: Clear "suspended" on reset/disconnect
[ Upstream commit 602fda17c7356bb7ae98467d93549057481d11dd ]
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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
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 b8a15840b4ff..dfcabadeed01 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) |