aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/umip.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2018-09-18 01:16:39 +0200
committerEric W. Biederman <ebiederm@xmission.com>2018-09-21 15:30:54 +0200
commit0a996c1a3f260ba6fe1201a668d31fa8d8339793 (patch)
tree24db881f7fa63a53e12d4d31a759cb1dd7293b64 /arch/x86/kernel/umip.c
parentsignal/x86: Pass pkey by value (diff)
downloadlinux-dev-0a996c1a3f260ba6fe1201a668d31fa8d8339793.tar.xz
linux-dev-0a996c1a3f260ba6fe1201a668d31fa8d8339793.zip
signal/x86: Use force_sig_fault where appropriate
Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to '')
-rw-r--r--arch/x86/kernel/umip.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/arch/x86/kernel/umip.c b/arch/x86/kernel/umip.c
index ff20b35e98dd..f8f3cfda01ae 100644
--- a/arch/x86/kernel/umip.c
+++ b/arch/x86/kernel/umip.c
@@ -271,19 +271,13 @@ static int emulate_umip_insn(struct insn *insn, int umip_inst,
*/
static void force_sig_info_umip_fault(void __user *addr, struct pt_regs *regs)
{
- siginfo_t info;
struct task_struct *tsk = current;
tsk->thread.cr2 = (unsigned long)addr;
tsk->thread.error_code = X86_PF_USER | X86_PF_WRITE;
tsk->thread.trap_nr = X86_TRAP_PF;
- clear_siginfo(&info);
- info.si_signo = SIGSEGV;
- info.si_errno = 0;
- info.si_code = SEGV_MAPERR;
- info.si_addr = addr;
- force_sig_info(SIGSEGV, &info, tsk);
+ force_sig_fault(SIGSEGV, SEGV_MAPERR, addr, tsk);
if (!(show_unhandled_signals && unhandled_signal(tsk, SIGSEGV)))
return;