Thread (49 messages) 49 messages, 9 authors, 2016-01-14

Re: [PATCH v3 02/22] kthread/smpboot: Do not park in kthread_create_on_cpu()

From: Thomas Gleixner <hidden>
Date: 2015-11-25 21:17:22
Also in: linux-mm, lkml

On Wed, 18 Nov 2015, Petr Mladek wrote:
kthread_create_on_cpu() was added by the commit 2a1d446019f9a5983e
("kthread: Implement park/unpark facility"). It is currently used
only when enabling new CPU. For this purpose, the newly created
kthread has to be parked.

The CPU binding is a bit tricky. The kthread is parked when the CPU
has not been allowed yet. And the CPU is bound when the kthread
is unparked.

The function would be useful for more per-CPU kthreads, e.g.
bnx2fc_thread, fcoethread. For this purpose, the newly created
kthread should stay in the uninterruptible state.

This patch moves the parking into smpboot. It binds the thread
already when created. Then the function might be used universally.
Also the behavior is consistent with kthread_create() and
kthread_create_on_node().

Signed-off-by: Petr Mladek <pmladek-IBi9RG/b67k@public.gmane.org>
Reviewed-by: Thomas Gleixner <redacted>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help