From: Oleg Nesterov <oleg@redhat.com>
To: Denys Vlasenko <vda.linux@googlemail.com>
Cc: linux-kernel@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
Amerigo Wang <amwang@redhat.com>,
"Jonathan M. Foote" <jmfoote@cert.org>,
Roland McGrath <roland@hack.frob.com>,
Pedro Alves <palves@redhat.com>
Subject: Re: [PATCH -mm v2 2/2] coredump: add a new elf note with siginfo of the signal
Date: Tue, 18 Sep 2012 17:30:27 +0200 [thread overview]
Message-ID: <20120918153027.GA21612@redhat.com> (raw)
In-Reply-To: <1347979995-1452-3-git-send-email-vda.linux@googlemail.com>
On 09/18, Denys Vlasenko wrote:
>
> +static void fill_siginfo_note(struct memelfnote *note, siginfo_t *csigdata, siginfo_t *siginfo)
> +{
> + mm_segment_t old_fs = get_fs();
> + set_fs(KERNEL_DS);
> + copy_siginfo_to_user((siginfo_t __user *) csigdata, siginfo);
> + set_fs(old_fs);
> + fill_note(note, "CORE", NT_SIGINFO, sizeof(*csigdata), csigdata);
> +}
OK, I think this is fine.
But, somehow I forgot about compat tasks when we discussed this before.
Perhaps the code above should do
if (is_compat_task())
copy_siginfo_to_user32(...);
else
copy_siginfo_to_user(...);
?
Oleg.
next prev parent reply other threads:[~2012-09-18 15:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-18 14:53 [PATCH -mm v2 0/2] coredump: add a new elf note with siginfo of the signal Denys Vlasenko
2012-09-18 14:53 ` [PATCH -mm v2 1/2] coredump: pass siginfo_t* to do_coredump() and below, not merely signr Denys Vlasenko
2012-09-18 14:53 ` [PATCH -mm v2 2/2] coredump: add a new elf note with siginfo of the signal Denys Vlasenko
2012-09-18 15:30 ` Oleg Nesterov [this message]
2012-09-18 16:41 ` Roland McGrath
2012-09-18 16:57 ` Oleg Nesterov
2012-09-19 16:06 ` Denys Vlasenko
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=20120918153027.GA21612@redhat.com \
--to=oleg@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=amwang@redhat.com \
--cc=jmfoote@cert.org \
--cc=linux-kernel@vger.kernel.org \
--cc=palves@redhat.com \
--cc=roland@hack.frob.com \
--cc=vda.linux@googlemail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.