diff options
author | Michal Simek <monstr@monstr.eu> | 2009-04-21 08:08:47 -0400 |
---|---|---|
committer | Michal Simek <monstr@monstr.eu> | 2009-04-23 10:27:33 -0400 |
commit | 2921e2bd679949a7892d308b414e6a3b3c705260 (patch) | |
tree | 4be639979e46583a1c6e2d12b26a78b989a8c49c /arch/microblaze/kernel | |
parent | 6dfb79aa114ac69032f3931235ffc90799e9630b (diff) |
microblaze: Add STATE_SAVE_ARG_SPACE for noMMU kernel too
For noMMU kernel this change nothing bring but this change
helps with MMU synchronization.
Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/kernel')
-rw-r--r-- | arch/microblaze/kernel/signal.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/arch/microblaze/kernel/signal.c b/arch/microblaze/kernel/signal.c index 3889cf45fa71..40d36931e363 100644 --- a/arch/microblaze/kernel/signal.c +++ b/arch/microblaze/kernel/signal.c | |||
@@ -178,7 +178,9 @@ restore_sigcontext(struct pt_regs *regs, struct sigcontext *sc, int *rval_p) | |||
178 | 178 | ||
179 | asmlinkage int sys_sigreturn(struct pt_regs *regs) | 179 | asmlinkage int sys_sigreturn(struct pt_regs *regs) |
180 | { | 180 | { |
181 | struct sigframe *frame = (struct sigframe *)regs->r1; | 181 | struct sigframe *frame = |
182 | (struct sigframe *)(regs->r1 + STATE_SAVE_ARG_SPACE); | ||
183 | |||
182 | sigset_t set; | 184 | sigset_t set; |
183 | int rval; | 185 | int rval; |
184 | 186 | ||
@@ -209,7 +211,9 @@ badframe: | |||
209 | 211 | ||
210 | asmlinkage int sys_rt_sigreturn(struct pt_regs *regs) | 212 | asmlinkage int sys_rt_sigreturn(struct pt_regs *regs) |
211 | { | 213 | { |
212 | struct rt_sigframe *frame = (struct rt_sigframe *)regs->r1; | 214 | struct rt_sigframe *frame = |
215 | (struct rt_sigframe *)(regs->r1 + STATE_SAVE_ARG_SPACE); | ||
216 | |||
213 | sigset_t set; | 217 | sigset_t set; |
214 | stack_t st; | 218 | stack_t st; |
215 | int rval; | 219 | int rval; |
@@ -336,7 +340,8 @@ static void setup_frame(int sig, struct k_sigaction *ka, | |||
336 | goto give_sigsegv; | 340 | goto give_sigsegv; |
337 | 341 | ||
338 | /* Set up registers for signal handler */ | 342 | /* Set up registers for signal handler */ |
339 | regs->r1 = (unsigned long) frame; | 343 | regs->r1 = (unsigned long) frame - STATE_SAVE_ARG_SPACE; |
344 | |||
340 | /* Signal handler args: */ | 345 | /* Signal handler args: */ |
341 | regs->r5 = signal; /* Arg 0: signum */ | 346 | regs->r5 = signal; /* Arg 0: signum */ |
342 | regs->r6 = (unsigned long) &frame->sc; /* arg 1: sigcontext */ | 347 | regs->r6 = (unsigned long) &frame->sc; /* arg 1: sigcontext */ |
@@ -414,7 +419,8 @@ static void setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, | |||
414 | goto give_sigsegv; | 419 | goto give_sigsegv; |
415 | 420 | ||
416 | /* Set up registers for signal handler */ | 421 | /* Set up registers for signal handler */ |
417 | regs->r1 = (unsigned long) frame; | 422 | regs->r1 = (unsigned long) frame - STATE_SAVE_ARG_SPACE; |
423 | |||
418 | /* Signal handler args: */ | 424 | /* Signal handler args: */ |
419 | regs->r5 = signal; /* arg 0: signum */ | 425 | regs->r5 = signal; /* arg 0: signum */ |
420 | regs->r6 = (unsigned long) &frame->info; /* arg 1: siginfo */ | 426 | regs->r6 = (unsigned long) &frame->info; /* arg 1: siginfo */ |