Re: [PATCH 4/7] sched: implement force_cpus_allowed()

From: Peter Zijlstra
Date: Tue Dec 08 2009 - 06:49:06 EST


On Tue, 2009-12-08 at 20:24 +0900, Tejun Heo wrote:
>
> Let me augment the above sentence. Yes, that's all I need *during
> CPU_DOWN*. During CPU_UP, I need to migrate back left running workers
> which survived from the last CPU_DOWN. In the original patch, the
> down path is worker_maybe_bind_and_lock() and the latter path is
> trustee_unset_rogue().

Why bother with that?

workqueue's CPU_POST_DEAD will flush the workqueue and destroy all
threads under cpu_add_remove_lock, which excludes the cpu from coming
back up before its fully destroyed.

So there's no remaining tasks to be migrated back.

Changing that semantics is not worthwhile.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/