aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/usb/controller/usb_controller.c
diff options
context:
space:
mode:
authorAndrew Thompson <thompsa@FreeBSD.org>2009-04-22 17:08:10 +0000
committerAndrew Thompson <thompsa@FreeBSD.org>2009-04-22 17:08:10 +0000
commit672c9965ef482f0b8b716c71d06d8e3d92db0a79 (patch)
treead3cdcdae8a41de670d6abe848c78cdc9bd26fd1 /sys/dev/usb/controller/usb_controller.c
parent39063699e6178e8a5d6dfc541d3c0bfd3b7c63a3 (diff)
downloadsrc-672c9965ef482f0b8b716c71d06d8e3d92db0a79.tar.gz
src-672c9965ef482f0b8b716c71d06d8e3d92db0a79.zip
MFp4 //depot/projects/usb@160706
Resolve possible device side mode deadlock by creating another thread. Submitted by: Hans Petter Selasky
Notes
Notes: svn path=/head/; revision=191400
Diffstat (limited to 'sys/dev/usb/controller/usb_controller.c')
-rw-r--r--sys/dev/usb/controller/usb_controller.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/dev/usb/controller/usb_controller.c b/sys/dev/usb/controller/usb_controller.c
index 474cbe5e9667..cf30051a5c2b 100644
--- a/sys/dev/usb/controller/usb_controller.c
+++ b/sys/dev/usb/controller/usb_controller.c
@@ -169,6 +169,10 @@ usb2_detach(device_t dev)
usb2_proc_free(&bus->explore_proc);
+ /* Get rid of control transfer process */
+
+ usb2_proc_free(&bus->control_xfer_proc);
+
return (0);
}
@@ -412,6 +416,10 @@ usb2_attach_sub(device_t dev, struct usb2_bus *bus)
&bus->bus_mtx, pname, USB_PRI_MED)) {
printf("WARNING: Creation of USB explore "
"process failed.\n");
+ } else if (usb2_proc_create(&bus->control_xfer_proc,
+ &bus->bus_mtx, pname, USB_PRI_MED)) {
+ printf("WARNING: Creation of USB control transfer "
+ "process failed.\n");
} else {
/* Get final attach going */
USB_BUS_LOCK(bus);