]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86_64/ia32/ia32_signal.c
Merge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds
[linux-2.6-omap-h63xx.git] / arch / x86_64 / ia32 / ia32_signal.c
index ff499ef2a1ba10674cba34782c546cbeac43a51a..6ea19c25f90d46ce209c646382443c5a8ae0e46e 100644 (file)
@@ -11,7 +11,6 @@
 #include <linux/sched.h>
 #include <linux/mm.h>
 #include <linux/smp.h>
-#include <linux/smp_lock.h>
 #include <linux/kernel.h>
 #include <linux/signal.h>
 #include <linux/errno.h>
@@ -21,6 +20,7 @@
 #include <linux/stddef.h>
 #include <linux/personality.h>
 #include <linux/compat.h>
+#include <linux/binfmts.h>
 #include <asm/ucontext.h>
 #include <asm/uaccess.h>
 #include <asm/i387.h>
@@ -449,7 +449,11 @@ int ia32_setup_frame(int sig, struct k_sigaction *ka,
 
        /* Return stub is in 32bit vsyscall page */
        { 
-               void __user *restorer = VSYSCALL32_SIGRETURN; 
+               void __user *restorer;
+               if (current->binfmt->hasvdso)
+                       restorer = VSYSCALL32_SIGRETURN;
+               else
+                       restorer = (void *)&frame->retcode;
                if (ka->sa.sa_flags & SA_RESTORER)
                        restorer = ka->sa.sa_restorer;       
                err |= __put_user(ptr_to_compat(restorer), &frame->pretcode);
@@ -495,7 +499,7 @@ int ia32_setup_frame(int sig, struct k_sigaction *ka,
                ptrace_notify(SIGTRAP);
 
 #if DEBUG_SIG
-       printk("SIG deliver (%s:%d): sp=%p pc=%p ra=%p\n",
+       printk("SIG deliver (%s:%d): sp=%p pc=%lx ra=%u\n",
                current->comm, current->pid, frame, regs->rip, frame->pretcode);
 #endif
 
@@ -601,7 +605,7 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info,
                ptrace_notify(SIGTRAP);
 
 #if DEBUG_SIG
-       printk("SIG deliver (%s:%d): sp=%p pc=%p ra=%p\n",
+       printk("SIG deliver (%s:%d): sp=%p pc=%lx ra=%u\n",
                current->comm, current->pid, frame, regs->rip, frame->pretcode);
 #endif