Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c4d9817a authored by Hemant Kumar's avatar Hemant Kumar
Browse files

usb: core: Allow secondary event ring clean upon disconnect



If device is disconnected in the middle of data transfer
there is a possibility of pending events in the secondary
event ring. As a result when xHC is halted as part of device
disconnect, device is not getting detected upon re-connect.
Fix the issue by acknowledging the pending events upon
device disconnect. Also this allows to finish the clean up
of event ring otherwise this results into a memory leak.

Change-Id: I2ec3d74867e0129dad395d1dbe920b468ac5949d
Signed-off-by: default avatarHemant Kumar <hemantk@codeaurora.org>
parent 83c03ff2
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -838,9 +838,6 @@ EXPORT_SYMBOL(usb_sec_event_ring_setup);
int usb_sec_event_ring_cleanup(struct usb_device *dev,
	unsigned int intr_num)
{
	if (dev->state == USB_STATE_NOTATTACHED)
		return 0;

	return usb_hcd_sec_event_ring_cleanup(dev, intr_num);
}
EXPORT_SYMBOL(usb_sec_event_ring_cleanup);