]> git.baikalelectronics.ru Git - kernel.git/commit
kernel: add a kernel_wait helper
authorChristoph Hellwig <hch@lst.de>
Wed, 12 Aug 2020 01:34:10 +0000 (18:34 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 12 Aug 2020 17:57:59 +0000 (10:57 -0700)
commitdc699100f16e2fb904699af55e3ccf50b570f801
tree05be60738ff9974830290aa6a4459336ecdd45d9
parent97c3ebe728e8764468503660cfc5034f30baba2c
kernel: add a kernel_wait helper

Add a helper that waits for a pid and stores the status in the passed in
kernel pointer.  Use it to fix the usage of kernel_wait4 in
call_usermodehelper_exec_sync that only happens to work due to the
implicit set_fs(KERNEL_DS) for kernel threads.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Luis Chamberlain <mcgrof@kernel.org>
Link: http://lkml.kernel.org/r/20200721130449.5008-1-hch@lst.de
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/sched/task.h
kernel/exit.c
kernel/umh.c