diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2018-04-17 23:23:48 +0300 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2018-04-25 18:40:33 +0300 |
commit | f6ed1ecad56fec7ab5c6bf741064b95801e9688f (patch) | |
tree | 55d26c715eb120bf5cfabb11dd1cee77e1ad3861 /arch/nds32 | |
parent | be5c2ff06c2a30fb694d54b0a100ef4f55e1de3a (diff) | |
download | linux-f6ed1ecad56fec7ab5c6bf741064b95801e9688f.tar.xz |
signal/nds32: Use force_sig(SIGILL) in do_revisn
As originally committed do_revisn would deliver a siginfo for SIGILL
with an si_code composed of random stack contents. That makes no
sense and is not something userspace can depend on. So simplify
the code and just use "force_sig(SIG_ILL, current)" instead.
Fixes: 2923f5ea7738 ("nds32: Exception handling")
Cc: Vincent Chen <vincentc@andestech.com>
Cc: Greentime Hu <greentime@andestech.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'arch/nds32')
-rw-r--r-- | arch/nds32/kernel/traps.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/arch/nds32/kernel/traps.c b/arch/nds32/kernel/traps.c index 65961bf91d64..8e9a5b1f6234 100644 --- a/arch/nds32/kernel/traps.c +++ b/arch/nds32/kernel/traps.c @@ -356,14 +356,11 @@ void do_dispatch_tlb_misc(unsigned long entry, unsigned long addr, void do_revinsn(struct pt_regs *regs) { - siginfo_t si; pr_emerg("Reserved Instruction\n"); show_regs(regs); if (!user_mode(regs)) do_exit(SIGILL); - si.si_signo = SIGILL; - si.si_errno = 0; - force_sig_info(SIGILL, &si, current); + force_sig(SIGILL, current); } #ifdef CONFIG_ALIGNMENT_TRAP |