signal/unicore32: Use force_sig_fault where appropriate
authorEric W. Biederman <ebiederm@xmission.com>
Thu, 19 Apr 2018 23:22:47 +0000 (18:22 -0500)
committerEric W. Biederman <ebiederm@xmission.com>
Thu, 27 Sep 2018 20:11:30 +0000 (22:11 +0200)
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
arch/unicore32/mm/fault.c

index a942776..b9a3a50 100644 (file)
@@ -120,17 +120,10 @@ static void __do_user_fault(struct task_struct *tsk, unsigned long addr,
                unsigned int fsr, unsigned int sig, int code,
                struct pt_regs *regs)
 {
-       struct siginfo si;
-
        tsk->thread.address = addr;
        tsk->thread.error_code = fsr;
        tsk->thread.trap_no = 14;
-       clear_siginfo(&si);
-       si.si_signo = sig;
-       si.si_errno = 0;
-       si.si_code = code;
-       si.si_addr = (void __user *)addr;
-       force_sig_info(sig, &si, tsk);
+       force_sig_fault(sig, code, (void __user *)addr, tsk);
 }
 
 void do_bad_area(unsigned long addr, unsigned int fsr, struct pt_regs *regs)