From: Oleg Nesterov <oleg@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Andi Kleen <andi@firstfloor.org>,
David Howells <dhowells@redhat.com>,
Neil Horman <nhorman@tuxdriver.com>,
Rusty Russell <rusty@rustcorp.com.au>,
linux-kernel@vger.kernel.org
Subject: [PATCH -mm 1/3] call_usermodehelper: no need to unblock the signals
Date: Tue, 9 Mar 2010 22:44:56 +0100 [thread overview]
Message-ID: <20100309214456.GA32617@redhat.com> (raw)
____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>
---
kernel/kmod.c | 3 ---
1 file changed, 3 deletions(-)
--- mm/kernel/kmod.c~1_SIGNALS 2010-02-26 22:07:38.000000000 +0100
+++ mm/kernel/kmod.c 2010-03-09 21:31:09.000000000 +0100
@@ -153,11 +153,8 @@ static int ____call_usermodehelper(void
struct subprocess_info *sub_info = data;
int retval;
- /* Unblock all signals */
spin_lock_irq(¤t->sighand->siglock);
flush_signal_handlers(current, 1);
- sigemptyset(¤t->blocked);
- recalc_sigpending();
spin_unlock_irq(¤t->sighand->siglock);
/* We can run anywhere, unlike our parent keventd(). */
reply other threads:[~2010-03-09 21:47 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100309214456.GA32617@redhat.com \
--to=oleg@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=andi@firstfloor.org \
--cc=dhowells@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nhorman@tuxdriver.com \
--cc=rusty@rustcorp.com.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox