Commit ca98565a authored by Guenter Roeck's avatar Guenter Roeck Committed by Linus Torvalds

unicore32: Fix build error

unicore32 builds fail with

  arch/unicore32/kernel/signal.c: In function ‘setup_frame’:
  arch/unicore32/kernel/signal.c:257: error: ‘usig’ undeclared (first use in this function)
  arch/unicore32/kernel/signal.c:279: error: ‘usig’ undeclared (first use in this function)
  arch/unicore32/kernel/signal.c: In function ‘handle_signal’:
  arch/unicore32/kernel/signal.c:306: warning: unused variable ‘tsk’
  arch/unicore32/kernel/signal.c: In function ‘do_signal’:
  arch/unicore32/kernel/signal.c:376: error: implicit declaration of function ‘get_signsl’
  make[1]: *** [arch/unicore32/kernel/signal.o] Error 1
  make: *** [arch/unicore32/kernel/signal.o] Error 2

Bisect points to commit 649671c9 ("unicore32: Use get_signal()
signal_setup_done()").

This code never even compiled.  Reverting the patch does not work, since
previously used functions no longer exist, so try to fix it up.  Compile
tested only.

Fixes: 649671c9 ("unicore32: Use get_signal() signal_setup_done()")
Cc: Richard Weinberger <richard@nod.at>
Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 94559a4a
...@@ -254,7 +254,8 @@ static int setup_frame(struct ksignal *ksig, sigset_t *set, ...@@ -254,7 +254,8 @@ static int setup_frame(struct ksignal *ksig, sigset_t *set,
err |= setup_sigframe(frame, regs, set); err |= setup_sigframe(frame, regs, set);
if (err == 0) if (err == 0)
err |= setup_return(regs, &ksig->ka, frame->retcode, frame, usig); err |= setup_return(regs, &ksig->ka, frame->retcode, frame,
ksig->sig);
return err; return err;
} }
...@@ -276,7 +277,8 @@ static int setup_rt_frame(struct ksignal *ksig, sigset_t *set, ...@@ -276,7 +277,8 @@ static int setup_rt_frame(struct ksignal *ksig, sigset_t *set,
err |= __save_altstack(&frame->sig.uc.uc_stack, regs->UCreg_sp); err |= __save_altstack(&frame->sig.uc.uc_stack, regs->UCreg_sp);
err |= setup_sigframe(&frame->sig, regs, set); err |= setup_sigframe(&frame->sig, regs, set);
if (err == 0) if (err == 0)
err |= setup_return(regs, &ksig->ka, frame->sig.retcode, frame, usig); err |= setup_return(regs, &ksig->ka, frame->sig.retcode, frame,
ksig->sig);
if (err == 0) { if (err == 0) {
/* /*
...@@ -303,7 +305,6 @@ static void handle_signal(struct ksignal *ksig, struct pt_regs *regs, ...@@ -303,7 +305,6 @@ static void handle_signal(struct ksignal *ksig, struct pt_regs *regs,
int syscall) int syscall)
{ {
struct thread_info *thread = current_thread_info(); struct thread_info *thread = current_thread_info();
struct task_struct *tsk = current;
sigset_t *oldset = sigmask_to_save(); sigset_t *oldset = sigmask_to_save();
int usig = ksig->sig; int usig = ksig->sig;
int ret; int ret;
...@@ -373,7 +374,7 @@ static void do_signal(struct pt_regs *regs, int syscall) ...@@ -373,7 +374,7 @@ static void do_signal(struct pt_regs *regs, int syscall)
if (!user_mode(regs)) if (!user_mode(regs))
return; return;
if (get_signsl(&ksig)) { if (get_signal(&ksig)) {
handle_signal(&ksig, regs, syscall); handle_signal(&ksig, regs, syscall);
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment