summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSaurav Girepunje <saurav.girepunje@gmail.com>2022-06-08 23:47:42 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-06-10 11:52:40 +0200
commit757bdf1f2fb5f1281cb13da5f24860ae81c6140e (patch)
treecf755d325f83db800d4ca375fed98e1c14d88410
parenta725d0f6dfc5d3739d6499f30ec865305ba3544d (diff)
usb: musb: remove schedule work called after flush
In musb_remove() cancel_delayed_work_sync(&musb->irq_work) is called which flush the irq_work work queue. After cancel delayed work, musb_remove() call musb_gadget_cleanup->usb_del_gadget_udc->usb_del_gadget ->usb_gadget_remove_driver->usb_gadget_udc_stop->udc ->gadget->ops->udc_stop(udc->gadget); Where musb_gadget_stop() call "schedule_delayed_work(&musb->irq_work, 0)” which is already cancel/flush. So remove the schedule_delayed_work(&musb->irq_work, 0); from musb_gadget_stop function. Signed-off-by: Saurav Girepunje <saurav.girepunje@gmail.com> Link: https://lore.kernel.org/r/YqDnxkWZV2KfZh5q@Sauravs-MacBook-Air.local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/usb/musb/musb_gadget.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c
index 51274b87f46c..daada4b66a92 100644
--- a/drivers/usb/musb/musb_gadget.c
+++ b/drivers/usb/musb/musb_gadget.c
@@ -1910,8 +1910,6 @@ static int musb_gadget_stop(struct usb_gadget *g)
*/
/* Force check of devctl register for PM runtime */
- schedule_delayed_work(&musb->irq_work, 0);
-
pm_runtime_mark_last_busy(musb->controller);
pm_runtime_put_autosuspend(musb->controller);