Commit 34f88c60 authored by Jeff Dike's avatar Jeff Dike Committed by Linus Torvalds

[PATCH] uml: more EINTR protection

This adds retrying on EINTR to a couple more places.
Signed-off-by: default avatarJeff Dike <jdike@addtoit.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 4cddaea4
...@@ -132,7 +132,7 @@ int run_helper_thread(int (*proc)(void *), void *arg, unsigned int flags, ...@@ -132,7 +132,7 @@ int run_helper_thread(int (*proc)(void *), void *arg, unsigned int flags,
return(-errno); return(-errno);
} }
if(stack_out == NULL){ if(stack_out == NULL){
pid = waitpid(pid, &status, 0); CATCH_EINTR(pid = waitpid(pid, &status, 0));
if(pid < 0){ if(pid < 0){
printk("run_helper_thread - wait failed, errno = %d\n", printk("run_helper_thread - wait failed, errno = %d\n",
errno); errno);
...@@ -151,7 +151,7 @@ int helper_wait(int pid, int block) ...@@ -151,7 +151,7 @@ int helper_wait(int pid, int block)
{ {
int ret; int ret;
ret = waitpid(pid, NULL, WNOHANG); CATCH_EINTR(ret = waitpid(pid, NULL, WNOHANG));
if(ret < 0){ if(ret < 0){
printk("helper_wait : waitpid failed, errno = %d\n", errno); printk("helper_wait : waitpid failed, errno = %d\n", errno);
return(-errno); return(-errno);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment