LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: dvlasenk@redhat.com
Cc: linux-tip-commits@vger.kernel.org, linux-kernel@vger.kernel.org,
	keescook@chromium.org, ast@plumgrid.com, fweisbec@gmail.com,
	oleg@redhat.com, tglx@linutronix.de,
	torvalds@linux-foundation.org, hpa@zytor.com, mingo@kernel.org,
	wad@chromium.org, rostedt@goodmis.org, dvlasenk@redhat.com
Subject: Re: [tip:x86/asm] x86/asm/entry/64: Remove unused thread_struct:: usersp
Date: Mon, 16 Mar 2015 17:47:07 +0100	[thread overview]
Message-ID: <20150316164707.GB23015@pd.tnic> (raw)
In-Reply-To: <tip-245214a155c711764b3853189441c9f8aeb058b3@git.kernel.org>

On Mon, Mar 16, 2015 at 05:05:53AM -0700, tip-bot for Denys Vlasenko wrote:
> Commit-ID:  245214a155c711764b3853189441c9f8aeb058b3
> Gitweb:     http://git.kernel.org/tip/245214a155c711764b3853189441c9f8aeb058b3
> Author:     Denys Vlasenko <dvlasenk@redhat.com>
> AuthorDate: Tue, 10 Mar 2015 11:45:07 +0100
> Committer:  Ingo Molnar <mingo@kernel.org>
> CommitDate: Tue, 10 Mar 2015 13:56:11 +0100
> 
> x86/asm/entry/64: Remove unused thread_struct::usersp
> 
> All manipulations of PER_CPU(old_rsp) in C code are removed:
> it is not used on SYSRET return, so storing anything there is
> pointless.
> 
> This also allows us to get rid of thread_struct::usersp,
> which was needed only to set PER_CPU(old_rsp) for correct
> return from fork/clone.
> 
> Tweak a few comments as well: we no longer have "partial stack frame",
> ever.
> 
> Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
> Cc: Alexei Starovoitov <ast@plumgrid.com>
> Cc: Borislav Petkov <bp@alien8.de>
> Cc: Frederic Weisbecker <fweisbec@gmail.com>
> Cc: H. Peter Anvin <hpa@zytor.com>
> Cc: Kees Cook <keescook@chromium.org>
> Cc: Linus Torvalds <torvalds@linux-foundation.org>
> Cc: Oleg Nesterov <oleg@redhat.com>
> Cc: Steven Rostedt <rostedt@goodmis.org>
> Cc: Will Drewry <wad@chromium.org>
> Link: http://lkml.kernel.org/r/1425984307-2143-2-git-send-email-dvlasenk@redhat.com
> Signed-off-by: Ingo Molnar <mingo@kernel.org>

So this patch is causing all kinds of segfaults when booting my kvm
guest here, see below.

Reverting it makes the segfaults go away but from looking at the patch,
I have no idea why it would even cause those segfaults.

[    5.285547] kmod[1316]: segfault at 738c08 ip 0000000000738c08 sp 00007ffdb6079c68 error 15
[    9.537606] tput[2716]: segfault at 0 ip           (null) sp 00007fffffffdbd0 error 14 in tput[400000+3000]
					  ^^^^^^^^^^^^^^^^^

Looks like rIP has went off somewhere in the weeds.

Hmmm...

[    4.593374] grep[998]: segfault at 7ffc3a9f4378 ip 00007fb8409fe1df sp 00007ffc3a9f4378 error 4 in ld-2.13.so[7fb8409e8000+20000]
[    4.593374] grep[998]: segfault at 7ffc3a9f4378 ip 00007fb8409fe1df sp 00007ffc3a9f4378 error 4 in ld-2.13.so[7fb8409e8000+20000]

[    7.160423] sed[1999]: segfault at 7ffe9998f778 ip 00007f37deef0b52 sp 00007ffe9998f778 error 4 in libc-2.13.so[7f37dee18000+182000]

[    4.593374] grep[998]: segfault at 7ffc3a9f4378 ip 00007fb8409fe1df sp 00007ffc3a9f4378 error 4 in ld-2.13.so[7fb8409e8000+20000]
[    7.160423] sed[1999]: segfault at 7ffe9998f778 ip 00007f37deef0b52 sp 00007ffe9998f778 error 4 in libc-2.13.so[7f37dee18000+182000]

[    4.593374] grep[998]: segfault at 7ffc3a9f4378 ip 00007fb8409fe1df sp 00007ffc3a9f4378 error 4 in ld-2.13.so[7fb8409e8000+20000]
[    7.160423] sed[1999]: segfault at 7ffe9998f778 ip 00007f37deef0b52 sp 00007ffe9998f778 error 4 in libc-2.13.so[7f37dee18000+182000]
[    5.607611] sed[1350]: segfault at 7ffddd4a4bf0 ip 00007ff24a11fafc sp 00007ffddd4a4bf0 error 4 in libc-2.13.so[7ff24a050000+182000]
[    9.820987] update-exim4.co[2755]: segfault at 7ffff79ab000 ip 00007ffff79ab000 sp 00007fffffffe278 error 15
[   10.580362] tput[3060]: segfault at 7ffff6376cb0 ip 00007ffff7df3422 sp 00007ffff6376cb0 error 4 in ld-2.13.so[7ffff7ddd000+20000]

[    5.607611] sed[1350]: segfault at 7ffddd4a4bf0 ip 00007ff24a11fafc sp 00007ffddd4a4bf0 error 4 in libc-2.13.so[7ff24a050000+182000]
[    9.820987] update-exim4.co[2755]: segfault at 7ffff79ab000 ip 00007ffff79ab000 sp 00007fffffffe278 error 15
[   10.580362] tput[3060]: segfault at 7ffff6376cb0 ip 00007ffff7df3422 sp 00007ffff6376cb0 error 4 in ld-2.13.so[7ffff7ddd000+20000]

-- 
Regards/Gruss,
    Boris.

ECO tip #101: Trim your mails when you reply.
--

  reply	other threads:[~2015-03-16 16:48 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-10 10:45 [PATCH 2/4] x86: entry_64.S: remove stub_iopl Denys Vlasenko
2015-03-10 10:45 ` [PATCH 4/4] x86: entry_64.S: remove unused thread_struct::usersp Denys Vlasenko
2015-03-11 12:55   ` Borislav Petkov
2015-03-11 15:19     ` Denys Vlasenko
2015-03-16 12:05   ` [tip:x86/asm] x86/asm/entry/64: Remove unused thread_struct:: usersp tip-bot for Denys Vlasenko
2015-03-16 16:47     ` Borislav Petkov [this message]
2015-03-16 22:20       ` [tip:x86/asm] x86/asm/entry/64: Remove unused thread_struct::usersp Denys Vlasenko
2015-03-17  7:08         ` Borislav Petkov
2015-03-17  7:13           ` Ingo Molnar
2015-03-17  7:21             ` Ingo Molnar
2015-03-17  7:39               ` Borislav Petkov
2015-03-17 12:22                 ` Denys Vlasenko
2015-03-17 12:51                   ` Denys Vlasenko
2015-03-17  7:51               ` Ingo Molnar
2015-03-17  8:06                 ` Borislav Petkov
2015-03-17  8:27                   ` Ingo Molnar
2015-03-17  9:01                     ` Borislav Petkov
2015-03-11 12:08 ` [PATCH 2/4] x86: entry_64.S: remove stub_iopl Borislav Petkov
2015-03-16 12:05 ` [tip:x86/asm] x86/asm/entry/64: Remove stub_iopl tip-bot for 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=20150316164707.GB23015@pd.tnic \
    --to=bp@alien8.de \
    --cc=ast@plumgrid.com \
    --cc=dvlasenk@redhat.com \
    --cc=fweisbec@gmail.com \
    --cc=hpa@zytor.com \
    --cc=keescook@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=oleg@redhat.com \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.org \
    --cc=wad@chromium.org \
    --subject='Re: [tip:x86/asm] x86/asm/entry/64: Remove unused thread_struct:: usersp' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).