Skip to content

Commit

Permalink
call_usermodehelper: no need to unblock signals
Browse files Browse the repository at this point in the history
____call_usermodehelper() correctly calls flush_signal_handlers() to set
SIG_DFL, but sigemptyset(->blocked) and recalc_sigpending() are not
needed.

This kthread was forked by workqueue thread, all signals must be unblocked
and ignored, no pending signal is possible.

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>
  • Loading branch information
Oleg Nesterov authored and Linus Torvalds committed May 27, 2010
1 parent c70a626 commit 363da40
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions kernel/kmod.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,8 @@ static int ____call_usermodehelper(void *data)
struct subprocess_info *sub_info = data;
int retval;

/* Unblock all signals */
spin_lock_irq(&current->sighand->siglock);
flush_signal_handlers(current, 1);
sigemptyset(&current->blocked);
recalc_sigpending();
spin_unlock_irq(&current->sighand->siglock);

/* We can run anywhere, unlike our parent keventd(). */
Expand Down

0 comments on commit 363da40

Please sign in to comment.