usb: gadget: Prevent race between composite_setup & USB disconnect
While doing usb disconnect the ep0 is disabled, therefore
when composite_setup tries to queue on ep0 endpoint,
the operation result in race between the two functions
leading slab poison error since the request is already freed.
Fix this by disabling irqs, introducing flush for any
pending works to be cleared and enabling the irqs back.
Change-Id: I82f7a428929905762bae17dedbe717e0110155c5
Signed-off-by:
Udipto Goswami <ugoswami@codeaurora.org>
Loading
Please register or sign in to comment