From: Linus Torvalds Date: Wed, 22 Jan 2014 01:46:31 +0000 (-0800) Subject: Merge branch 'for-3.14' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq X-Git-Tag: v3.14-rc1~138 X-Git-Url: http://git.cascardo.eti.br/?a=commitdiff_plain;h=4a2829b97654ec773dabc681f232ab11cb347d01;p=cascardo%2Flinux.git Merge branch 'for-3.14' of git://git./linux/kernel/git/tj/wq Pull workqueue update from Tejun Heo: "Just one patch to add destroy_work_on_stack() annotations to help debugobj debugging" * 'for-3.14' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq: workqueue: Calling destroy_work_on_stack() to pair with INIT_WORK_ONSTACK() --- 4a2829b97654ec773dabc681f232ab11cb347d01 diff --cc kernel/workqueue.c index b010eac595d2,00df11270325..82ef9f3b7473 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@@ -4827,7 -4815,15 +4828,8 @@@ long work_on_cpu(int cpu, long (*fn)(vo INIT_WORK_ONSTACK(&wfc.work, work_for_cpu_fn); schedule_work_on(cpu, &wfc.work); - - /* - * The work item is on-stack and can't lead to deadlock through - * flushing. Use __flush_work() to avoid spurious lockdep warnings - * when work_on_cpu()s are nested. - */ - __flush_work(&wfc.work); - + flush_work(&wfc.work); + destroy_work_on_stack(&wfc.work); return wfc.ret; } EXPORT_SYMBOL_GPL(work_on_cpu);