diff options
author | Oleg Nesterov <oleg@redhat.com> | 2016-09-16 08:45:44 +0300 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-09-16 10:18:53 +0300 |
commit | 23196f2e5f5d810578a772785807dcdc2b9fdce9 (patch) | |
tree | e08ab0942b1b3ae15144633fb0eb2a67d45bfe4c /arch/x86/kernel/dumpstack_64.c | |
parent | c6c314a613cd7d03fb97713e0d642b493de42e69 (diff) | |
download | linux-23196f2e5f5d810578a772785807dcdc2b9fdce9.tar.xz |
kthread: Pin the stack via try_get_task_stack()/put_task_stack() in to_live_kthread() function
get_task_struct(tsk) no longer pins tsk->stack so all users of
to_live_kthread() should do try_get_task_stack/put_task_stack to protect
"struct kthread" which lives on kthread's stack.
TODO: Kill to_live_kthread(), perhaps we can even kill "struct kthread" too,
and rework kthread_stop(), it can use task_work_add() to sync with the exiting
kernel thread.
Message-Id: <20160629180357.GA7178@redhat.com>
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Andy Lutomirski <luto@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Jann Horn <jann@thejh.net>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/cb9b16bbc19d4aea4507ab0552e4644c1211d130.1474003868.git.luto@kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/kernel/dumpstack_64.c')
0 files changed, 0 insertions, 0 deletions