[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <4C7FBC660200007800013F95@vpn.id2.novell.com>
Date: Thu, 02 Sep 2010 14:01:58 +0100
From: "Jan Beulich" <JBeulich@...ell.com>
To: <mingo@...e.hu>, <tglx@...utronix.de>, <hpa@...or.com>
Cc: <arnd@...db.de>, <linux-kernel@...r.kernel.org>
Subject: [PATCH] i386: make kernel_execve() suitable for stack
unwinding
The explicit saving and restoring of %ebx was confusing stack unwind
data consumers, and it is plain unnecessary to do this within the
asm(), since that was only introduced for PIC user mode consumers of
the original _syscall3() macro this was derived from.
Signed-off-by: Jan Beulich <jbeulich@...ell.com>
Cc: Arnd Bergmann <arnd@...db.de>
---
arch/x86/kernel/sys_i386_32.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- linux-2.6.36-rc3/arch/x86/kernel/sys_i386_32.c
+++ 2.6.36-rc3-i386-unwind-annotations/arch/x86/kernel/sys_i386_32.c
@@ -33,8 +33,8 @@ int kernel_execve(const char *filename,
const char *const envp[])
{
long __res;
- asm volatile ("push %%ebx ; movl %2,%%ebx ; int $0x80 ; pop %%ebx"
+ asm volatile ("int $0x80"
: "=a" (__res)
- : "0" (__NR_execve), "ri" (filename), "c" (argv), "d" (envp) : "memory");
+ : "0" (__NR_execve), "b" (filename), "c" (argv), "d" (envp) : "memory");
return __res;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists