mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 19:30:30 +09:00
usb: gadget: composite: Clear "suspended" on reset/disconnect
[ Upstream commit 602fda17c7 ]
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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
21ec20f62f
commit
122ab8ea64
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user