svn commit: r212489 - user/weongyo/usb/sys/dev/usb/controller
Weongyo Jeong
weongyo at FreeBSD.org
Sun Sep 12 00:53:10 UTC 2010
Author: weongyo
Date: Sun Sep 12 00:53:10 2010
New Revision: 212489
URL: http://svn.freebsd.org/changeset/base/212489
Log:
Adds a comment why the thread count should be 1.
Modified:
user/weongyo/usb/sys/dev/usb/controller/usb_controller.c
Modified: user/weongyo/usb/sys/dev/usb/controller/usb_controller.c
==============================================================================
--- user/weongyo/usb/sys/dev/usb/controller/usb_controller.c Sun Sep 12 00:49:16 2010 (r212488)
+++ user/weongyo/usb/sys/dev/usb/controller/usb_controller.c Sun Sep 12 00:53:10 2010 (r212489)
@@ -402,6 +402,10 @@ usb_attach_sub(device_t dev, struct usb_
/* Initialise USB explore taskqueue and tasks */
bus->explore_tq = taskqueue_create("usb_explore_taskq", M_WAITOK,
taskqueue_thread_enqueue, &bus->explore_tq);
+ /*
+ * NOTE: the thread count always should be 1. If more, it couldn't
+ * guarantee the serialization between attach, detach and explore.
+ */
taskqueue_start_threads(&bus->explore_tq, 1, USB_PRI_MED,
"USB explore taskq");
TASK_INIT(&bus->attach_task, 0, usb_bus_attach, bus);
More information about the svn-src-user
mailing list