summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorOleg Nesterov <oleg@redhat.com>2010-05-26 14:43:05 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-27 09:12:45 -0700
commit04b1c384fbc4e0209e5c1affb67050886376d44b (patch)
tree19bc8690113dd6ded88d465a0777cb8bf7e33262 /kernel
parentd47419cd967a4f032a194148a7b08afad32faded (diff)
downloadop-kernel-dev-04b1c384fbc4e0209e5c1affb67050886376d44b.zip
op-kernel-dev-04b1c384fbc4e0209e5c1affb67050886376d44b.tar.gz
call_usermodehelper: UMH_WAIT_EXEC ignores kernel_thread() failure
UMH_WAIT_EXEC should report the error if kernel_thread() fails, like UMH_WAIT_PROC does. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/kmod.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/kmod.c b/kernel/kmod.c
index ad9f2ed..6e9b196 100644
--- a/kernel/kmod.c
+++ b/kernel/kmod.c
@@ -235,10 +235,10 @@ static void __call_usermodehelper(struct work_struct *work)
case UMH_WAIT_PROC:
if (pid > 0)
break;
- sub_info->retval = pid;
/* FALLTHROUGH */
-
case UMH_WAIT_EXEC:
+ if (pid < 0)
+ sub_info->retval = pid;
complete(sub_info->complete);
}
}
OpenPOWER on IntegriCloud