usb: gadget: f_mbim: Fix cpkt_resp_q list corruption on disconnect
mbim_write drops lock before queuing the request to controller.
If USB gets disconnected or composition switch happens before
lock is acquired again then ep_queue fails and driver tries to
delete cpkt_list which is already deleted and freed, causing
corruption. Add dev->online check after acquiring the spin_lock
to check USB connection state.
CRs-fixed: 849289
Change-Id: I1de570e45b3ceff3e3af61e4a78682ef8dac77ad
Signed-off-by:
Manu Gautam <mgautam@codeaurora.org>
Loading
Please register or sign in to comment