aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m32r/kernel/signal.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/m32r/kernel/signal.c')
-rw-r--r--arch/m32r/kernel/signal.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/arch/m32r/kernel/signal.c b/arch/m32r/kernel/signal.c
index 8c25e0c8f6a5..1c81e24fd006 100644
--- a/arch/m32r/kernel/signal.c
+++ b/arch/m32r/kernel/signal.c
@@ -172,20 +172,14 @@ static int setup_rt_frame(struct ksignal *ksig, sigset_t *set,
172{ 172{
173 struct rt_sigframe __user *frame; 173 struct rt_sigframe __user *frame;
174 int err = 0; 174 int err = 0;
175 int signal, sig = ksig->sig; 175 int sig = ksig->sig;
176 176
177 frame = get_sigframe(ksig, regs->spu, sizeof(*frame)); 177 frame = get_sigframe(ksig, regs->spu, sizeof(*frame));
178 178
179 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame))) 179 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame)))
180 return -EFAULT; 180 return -EFAULT;
181 181
182 signal = current_thread_info()->exec_domain 182 err |= __put_user(sig, &frame->sig);
183 && current_thread_info()->exec_domain->signal_invmap
184 && sig < 32
185 ? current_thread_info()->exec_domain->signal_invmap[sig]
186 : sig;
187
188 err |= __put_user(signal, &frame->sig);
189 if (err) 183 if (err)
190 return -EFAULT; 184 return -EFAULT;
191 185
@@ -209,7 +203,7 @@ static int setup_rt_frame(struct ksignal *ksig, sigset_t *set,
209 203
210 /* Set up registers for signal handler */ 204 /* Set up registers for signal handler */
211 regs->spu = (unsigned long)frame; 205 regs->spu = (unsigned long)frame;
212 regs->r0 = signal; /* Arg for signal handler */ 206 regs->r0 = sig; /* Arg for signal handler */
213 regs->r1 = (unsigned long)&frame->info; 207 regs->r1 = (unsigned long)&frame->info;
214 regs->r2 = (unsigned long)&frame->uc; 208 regs->r2 = (unsigned long)&frame->uc;
215 regs->bpc = (unsigned long)ksig->ka.sa.sa_handler; 209 regs->bpc = (unsigned long)ksig->ka.sa.sa_handler;