From: Harvey Harrison Date: Fri, 8 Feb 2008 20:09:57 +0000 (-0800) Subject: x86: make X86_32 pt_regs members unsigned long X-Git-Tag: v2.6.26-rc1~1154^2~596 X-Git-Url: http://git.samba.org/samba.git/?p=sfrench%2Fcifs-2.6.git;a=commitdiff_plain;h=9902a702c76f904be0057f8647dda9d6f89d4847;hp=92bc2056855b3250bf6fd5849f05f88d85839efa x86: make X86_32 pt_regs members unsigned long Signed-off-by: Harvey Harrison Cc: Roland McGrath Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner --- diff --git a/arch/x86/kernel/signal_32.c b/arch/x86/kernel/signal_32.c index 34fc0416b135..b1e97e80a57c 100644 --- a/arch/x86/kernel/signal_32.c +++ b/arch/x86/kernel/signal_32.c @@ -527,7 +527,7 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, int ret; /* Are we from a system call? */ - if (regs->orig_ax >= 0) { + if ((long)regs->orig_ax >= 0) { /* If so, check system call restarting.. */ switch (regs->ax) { case -ERESTART_RESTARTBLOCK: @@ -625,7 +625,7 @@ static void do_signal(struct pt_regs *regs) } /* Did we come from a system call? */ - if (regs->orig_ax >= 0) { + if ((long)regs->orig_ax >= 0) { /* Restart the system call - no handlers present */ switch (regs->ax) { case -ERESTARTNOHAND: diff --git a/include/asm-x86/ptrace.h b/include/asm-x86/ptrace.h index 708337a36727..bc442461ac64 100644 --- a/include/asm-x86/ptrace.h +++ b/include/asm-x86/ptrace.h @@ -42,12 +42,12 @@ struct pt_regs { unsigned long si; unsigned long di; unsigned long bp; - long ax; + unsigned long ax; unsigned long ds; unsigned long es; unsigned long fs; /* int gs; */ - long orig_ax; + unsigned long orig_ax; unsigned long ip; unsigned long cs; unsigned long flags; @@ -145,7 +145,10 @@ extern void send_sigtrap(struct task_struct *tsk, struct pt_regs *regs, int erro void signal_fault(struct pt_regs *regs, void __user *frame, char *where); #endif -#define regs_return_value(regs) ((regs)->ax) +static inline unsigned long regs_return_value(struct pt_regs *regs) +{ + return regs->ax; +} /* * user_mode_vm(regs) determines whether a register set came from user mode.