diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-03-11 09:47:28 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-03-11 09:47:28 -0700 |
commit | baadac8b10c5ac15ce3d26b68fa266c8889b163f (patch) | |
tree | 8ab1c758f8b2fe21351102d9845c0f8ec81a52cf /arch/x86/kernel/ptrace.c | |
parent | 051a82fc0c450f6ca649acf684586477aa6d5c6a (diff) | |
parent | 985a34bd75cc8c96e43f00dcdda7c3fdb51a3026 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86:
x86: remove quicklists
x86: ia32 syscall restart fix
x86: ioremap, remove WARN_ON()
Diffstat (limited to 'arch/x86/kernel/ptrace.c')
-rw-r--r-- | arch/x86/kernel/ptrace.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c index 8f64abe699f..d5904eef1d3 100644 --- a/arch/x86/kernel/ptrace.c +++ b/arch/x86/kernel/ptrace.c @@ -1055,10 +1055,17 @@ static int putreg32(struct task_struct *child, unsigned regno, u32 value) R32(esi, si); R32(ebp, bp); R32(eax, ax); - R32(orig_eax, orig_ax); R32(eip, ip); R32(esp, sp); + case offsetof(struct user32, regs.orig_eax): + /* + * Sign-extend the value so that orig_eax = -1 + * causes (long)orig_ax < 0 tests to fire correctly. + */ + regs->orig_ax = (long) (s32) value; + break; + case offsetof(struct user32, regs.eflags): return set_flags(child, value); |