summaryrefslogtreecommitdiff
path: root/kernel/workqueue.c
diff options
context:
space:
mode:
authorNathan T. Lynch <ntl@pobox.com>2005-02-15 23:15:27 -0800
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-02-15 23:15:27 -0800
commitd23b7e0d9c87e1479cd73255e049721acb914bbc (patch)
tree664b9d923290d963b28f34a11a2b055a524ffae8 /kernel/workqueue.c
parent36f288e82fb2d4acba7a74c1016d6b18ca04ae03 (diff)
[PATCH] kthread_bind new worker threads when onlining cpu
We weren't binding new worker threads to their cpu when onlining. Using preempt and the debug version of smp_processor_id found this. Signed-off-by: Nathan Lynch <ntl@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/workqueue.c')
-rw-r--r--kernel/workqueue.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 3993f7bdf5c2..5301935f609b 100644
--- a/kernel/workqueue.c
+++ b/kernel/workqueue.c
@@ -485,8 +485,10 @@ static int __devinit workqueue_cpu_callback(struct notifier_block *nfb,
case CPU_ONLINE:
/* Kick off worker threads. */
- list_for_each_entry(wq, &workqueues, list)
+ list_for_each_entry(wq, &workqueues, list) {
+ kthread_bind(wq->cpu_wq[hotcpu].thread, hotcpu);
wake_up_process(wq->cpu_wq[hotcpu].thread);
+ }
break;
case CPU_UP_CANCELED: