From: Jiri Slaby <jslaby@suse.cz>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: stable <stable@vger.kernel.org>,
"linux-arch@vger.kernel.org" <linux-arch@vger.kernel.org>
Subject: Re: [patch added to the 3.12 stable tree] vm: add VM_FAULT_SIGSEGV handling support
Date: Thu, 12 Mar 2015 17:23:11 +0100 [thread overview]
Message-ID: <5501BD6F.6010903@suse.cz> (raw)
In-Reply-To: <CA+55aFyxTvdC6u9RPdY2Pg=ALrHkHKHLt9+tY01RqKABP9cFPw@mail.gmail.com>
On 03/12/2015, 05:16 PM, Linus Torvalds wrote:
> On Thu, Mar 12, 2015 at 8:52 AM, Jiri Slaby <jslaby@suse.cz> wrote:
>>
>> diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c
>> index 5b90bbcad9f6..d9d8d91a64ff 100644
>> --- a/arch/x86/mm/fault.c
>> +++ b/arch/x86/mm/fault.c
>> @@ -873,6 +873,8 @@ mm_fault_error(struct pt_regs *regs, unsigned long error_code,
>> if (fault & (VM_FAULT_SIGBUS|VM_FAULT_HWPOISON|
>> VM_FAULT_HWPOISON_LARGE))
>> do_sigbus(regs, error_code, address, fault);
>> + else if (fault & VM_FAULT_SIGSEGV)
>> + bad_area_nosemaphore(regs, error_code, address);
>> else
>> BUG();
>> }
>
> Just double-checking that you are aware that this semantically depends
> on commit 7fb08eca4527 ("x86: mm: move mmap_sem unlock from
> mm_fault_error() to caller"). We had that back-porting bug at least
> twice, because it was so subtle.
>
> So either you need to backport 7fb08eca4527 too before (so that we
> really have dropped the semaphore at this point), or that
> "bad_area_nosemaphore()" needs to be just a "bad_area()" instead,
> because we still hold the semaphore.
Thanks for the heads-up. Despite I saw that one coming along with the
series to 3.10, I didn't include it due to a bit misleading commit
message. From that, it occurred to me like a cleanup.
Now included. Thanks.
--
js
suse labs
prev parent reply other threads:[~2015-03-12 16:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-12 15:52 [patch added to the 3.12 stable tree] vm: add VM_FAULT_SIGSEGV handling support Jiri Slaby
2015-03-12 15:52 ` [patch added to the 3.12 stable tree] vm: make stack guard page errors return VM_FAULT_SIGSEGV rather than SIGBUS Jiri Slaby
2015-03-12 16:16 ` [patch added to the 3.12 stable tree] vm: add VM_FAULT_SIGSEGV handling support Linus Torvalds
2015-03-12 16:23 ` Jiri Slaby [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=5501BD6F.6010903@suse.cz \
--to=jslaby@suse.cz \
--cc=linux-arch@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
/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.