From: Felipe Balbi Date: Mon, 15 Jul 2013 09:36:35 +0000 (+0300) Subject: usb: dwc3: gadget: don't prevent gadget from being probed if we fail X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cdcedd6981194e511cc206887db661d016069d68;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git usb: dwc3: gadget: don't prevent gadget from being probed if we fail In case we fail our ->udc_start() callback, we should be ready to accept another modprobe following the failed one. We had forgotten to clear dwc->gadget_driver back to NULL and, because of that, we were preventing gadget driver modprobe from being retried. Cc: Signed-off-by: Felipe Balbi --- diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index b5e5b35df49c..f77083fedc68 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -1584,6 +1584,7 @@ err1: __dwc3_gadget_ep_disable(dwc->eps[0]); err0: + dwc->gadget_driver = NULL; spin_unlock_irqrestore(&dwc->lock, flags); return ret;