From: Oleg Nesterov <oleg@redhat.com>
To: Ying Han <yinghan@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
menage@google.com, penberg@cs.helsinki.fi,
nickpiggin@yahoo.com.au, hugh@veritas.com, matthew@wil.cx,
rientjes@google.com, linux-kernel@vger.kernel.org
Subject: Re: + make-get_user_pages-interruptible.patch added to -mm tree
Date: Tue, 2 Dec 2008 14:26:09 +0100 [thread overview]
Message-ID: <20081202132609.GA8159@redhat.com> (raw)
In-Reply-To: <604427e00812011517tbf5685fr7263225aaa3adb3f@mail.gmail.com>
On 12/01, Ying Han wrote:
>
> On Mon, Dec 1, 2008 at 3:09 PM, Andrew Morton <akpm@linux-foundation.org> wrote:
> >
> > Note that fatal_signal_pending() is not an exact replacement for
> > sigkill_pending() - fatal_signal_pending() doesn't test the shared
> > pending signals.
> >
> yeah, i noticed that and that is why i used the sigkill_pending
> initially. But after a deeper look
> at the signal code, i found for SIGKILL ( signal we care about in this
> patch ), tsk->pending is a
> superset of tsk->signal->shared_pending.
Yes. If we have SIGKILL in ->shared_pending, we must have it in
in ->pending too.
The only exception is when we send SIGKILL to the already dying task
which has already dequeued SIGKILL from ->pending. And we do have a
special case: coredumping. elf_core_dump() does get_user_pages()
when the process is "almost" dead, it has SIGNAL_GROUP_EXIT.
So, if get_user_pages() calls sigkill_pending() instead of
fatal_signal_pending(), this can help. But:
- this relies on the fact that we always queue SIGKILL
even if the task is dead. This behaviour can be changed.
- this doesn't stop the coredumping, it will continue
with DUMP_SEEK(). Yes, this is better if we want to
stop this thread to populate the memory, but I think
we should just fix the coredumping - it should be
interruptible.
Actually, the patch exists:
http://marc.info/?l=linux-kernel&m=121665710711931
Oleg.
prev parent reply other threads:[~2008-12-02 13:28 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-27 20:04 + make-get_user_pages-interruptible.patch added to -mm tree Oleg Nesterov
2008-12-01 23:00 ` Ying Han
2008-12-01 23:09 ` Andrew Morton
2008-12-01 23:17 ` Ying Han
2008-12-02 13:26 ` Oleg Nesterov [this message]
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=20081202132609.GA8159@redhat.com \
--to=oleg@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=hugh@veritas.com \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew@wil.cx \
--cc=menage@google.com \
--cc=nickpiggin@yahoo.com.au \
--cc=penberg@cs.helsinki.fi \
--cc=rientjes@google.com \
--cc=yinghan@google.com \
/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