usb: gadget: f_mtp: Failing receive_file_work if state is OFFLINE
If unbind and receive_file_work takes place in parallel,
since unbind has the mutex_lock first receive_file_work
must wait until it is freed. Once it gets the mutex_lock it
starts processing again but till then unbind would have
cleared the request which leads to a slab poison error.
Fix this by check inside receive_file_work after mutex_lock
if the state is offline and bail out.
Change-Id: I27c7ed3d75c46d4d360b0d3d798924b5254a0216
Signed-off-by:
Udipto Goswami <ugoswami@codeaurora.org>
Loading
Please register or sign in to comment