From: Brian Gerst <brgerst@gmail.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: mingo@redhat.com, hpa@zytor.com, linux-kernel@vger.kernel.org,
tglx@linutronix.de, linux-tip-commits@vger.kernel.org
Subject: Re: [tip:x86/asm] x86-64: Use normal ptregs stub for execve
Date: Wed, 27 Jan 2010 10:21:15 -0500 [thread overview]
Message-ID: <73c1f2161001270721x3d07b507lb78fa8c53567dcaa@mail.gmail.com> (raw)
In-Reply-To: <20100127130716.GA26908@elte.hu>
On Wed, Jan 27, 2010 at 8:07 AM, Ingo Molnar <mingo@elte.hu> wrote:
>
> * tip-bot for Brian Gerst <brgerst@gmail.com> wrote:
>
>> Commit-ID: f19a25c872b20ae4357f72687cf3e7b0da220ee2
>> Gitweb: http://git.kernel.org/tip/f19a25c872b20ae4357f72687cf3e7b0da220ee2
>> Author: Brian Gerst <brgerst@gmail.com>
>> AuthorDate: Mon, 25 Jan 2010 10:47:33 -0500
>> Committer: H. Peter Anvin <hpa@zytor.com>
>> CommitDate: Tue, 26 Jan 2010 23:38:14 -0800
>>
>> x86-64: Use normal ptregs stub for execve
>>
>> Execve historically passed regs by value, so it had a seperate stub.
>> This is no longer true, so change it to use a normal PTREGSCALL stub.
>>
>> Signed-off-by: Brian Gerst <brgerst@gmail.com>
>> LKML-Reference: <1264434453-2204-1-git-send-email-brgerst@gmail.com>
>> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
>> ---
>> arch/x86/kernel/entry_64.S | 17 +----------------
>> 1 files changed, 1 insertions(+), 16 deletions(-)
>
> FYI, -tip testing found that this commit breaks the grub binary on 64-bit,
> simply running /sbin/grub causes it to segfault:
>
> [ 3145.999766] grub[6706] general protection ip:805c481 sp:ff95629c error:0 in
> grub[8048000+8c000]
>
> i've excluded this commit for now.
>
> Ingo
>
>
I see what is going on. Grub is a 32-bit statically linked executable
even on a 64-bit distro. The old execve stub forced return to
userspace via iret, but PTREGSCALL apparently doesn't. This means
that the 32-bit %cs isn't getting set. Drop this patch for now.
--
Brian Gerst
next prev parent reply other threads:[~2010-01-27 15:21 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-25 15:47 [PATCH] " Brian Gerst
2010-01-27 8:39 ` [tip:x86/asm] " tip-bot for Brian Gerst
2010-01-27 13:07 ` Ingo Molnar
2010-01-27 15:21 ` Brian Gerst [this message]
2010-01-27 16:28 ` H. Peter Anvin
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=73c1f2161001270721x3d07b507lb78fa8c53567dcaa@mail.gmail.com \
--to=brgerst@gmail.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mingo@redhat.com \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®