projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6027f31
)
usb: udc-core: set gadget state as not attached after unloading module
author
Peter Chen
<peter.chen@freescale.com>
Tue, 29 Apr 2014 05:26:29 +0000
(13:26 +0800)
committer
Felipe Balbi
<balbi@ti.com>
Mon, 12 May 2014 17:34:47 +0000
(12:34 -0500)
Set gadget state as "not attached" after unloading gadget module, or
its state will be unchanged after we unload gadget module.
Signed-off-by: Peter Chen <peter.chen@freescale.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/udc-core.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/usb/gadget/udc-core.c
b/drivers/usb/gadget/udc-core.c
index 27768a7d986a7f84e66d510be82cab2c513c7367..b0d98172bc0740dddb7da60eb210c0787aeb7a7b 100644
(file)
--- a/
drivers/usb/gadget/udc-core.c
+++ b/
drivers/usb/gadget/udc-core.c
@@
-428,6
+428,8
@@
int usb_gadget_unregister_driver(struct usb_gadget_driver *driver)
list_for_each_entry(udc, &udc_list, list)
if (udc->driver == driver) {
usb_gadget_remove_driver(udc);
+ usb_gadget_set_state(udc->gadget,
+ USB_STATE_NOTATTACHED);
ret = 0;
break;
}