Commit 31b994a4 authored by Marek Szyprowski's avatar Marek Szyprowski Committed by Felipe Balbi

usb: gadget: remove driver from pending list on probe error

Retry gadget probe only if the probe result is -EPROBE_DEFER, not on
every probe error.
Signed-off-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
parent bba40e69
......@@ -413,9 +413,10 @@ int usb_add_gadget_udc_release(struct device *parent, struct usb_gadget *gadget,
if (!driver->udc_name || strcmp(driver->udc_name,
dev_name(&udc->dev)) == 0) {
ret = udc_bind_to_driver(udc, driver);
if (ret != -EPROBE_DEFER)
list_del(&driver->pending);
if (ret)
goto err4;
list_del(&driver->pending);
break;
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment