diff options
author | Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> | 2018-11-07 15:12:49 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-09-16 08:22:14 +0200 |
commit | 7edfa9c99d215db6ef5df1038de5b36bcfa1bb63 (patch) | |
tree | f550f194b71e05a103077c21611c87e4d963efa0 /arch/arc/mm/fault.c | |
parent | 0828438e523e084420d381805c60d3dccba1f7a7 (diff) | |
download | linux-stable-7edfa9c99d215db6ef5df1038de5b36bcfa1bb63.tar.gz linux-stable-7edfa9c99d215db6ef5df1038de5b36bcfa1bb63.tar.bz2 linux-stable-7edfa9c99d215db6ef5df1038de5b36bcfa1bb63.zip |
ARC: mm: fix uninitialised signal code in do_page_fault
[ Upstream commit 121e38e5acdc8e1e4cdb750fcdcc72f94e420968 ]
Commit 15773ae938d8 ("signal/arc: Use force_sig_fault where
appropriate") introduced undefined behaviour by leaving si_code
unitiailized and leaking random kernel values to user space.
Fixes: 15773ae938d8 ("signal/arc: Use force_sig_fault where appropriate")
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'arch/arc/mm/fault.c')
-rw-r--r-- | arch/arc/mm/fault.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arc/mm/fault.c b/arch/arc/mm/fault.c index a0366f9dca05..535cf18e8bf2 100644 --- a/arch/arc/mm/fault.c +++ b/arch/arc/mm/fault.c @@ -66,7 +66,7 @@ void do_page_fault(unsigned long address, struct pt_regs *regs) struct vm_area_struct *vma = NULL; struct task_struct *tsk = current; struct mm_struct *mm = tsk->mm; - int si_code; + int si_code = 0; int ret; vm_fault_t fault; int write = regs->ecr_cause & ECR_C_PROTV_STORE; /* ST/EX */ |