"...0d0cea2424ae97b27447dc64a7dbfae83c036c45b403392f0e8ba.png" did not exist on "abd876b3b5fc80dc302183cd372067bab40efab5"
usb: gadget: f_mtp: Avoid race between mtp_read and mtp_function_disable
While mtp_read is being executed and mtp_function_disable
is called then all the eps will be disabled which will
lead to NULL pointer dereference in usb_ep_align_maybe
function which will subsequently try to access endpoint
descriptors.
Add spinlock protection in mtp_function_disable to
avoid race between mtp_read and mtp_function_disable.
Change-Id: If7f00ff2a98f75d2782e6bb35ad5fe59e4db6734
Signed-off-by:
Pratham Pratap <prathampratap@codeaurora.org>
Loading
Please register or sign in to comment