Commit bf2ce385 authored by Heiko Carstens's avatar Heiko Carstens Committed by Vasily Gorbik

s390/mm: remove unused access parameter from do_fault_error()

Remove unused access parameter from do_fault_error() which also makes the
code a bit more readable since quite some callers can be simplified.
Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
parent 9aa10e79
......@@ -268,8 +268,7 @@ static noinline void do_sigbus(struct pt_regs *regs)
(void __user *)(regs->int_parm_long & __FAIL_ADDR_MASK));
}
static noinline void do_fault_error(struct pt_regs *regs, int access,
vm_fault_t fault)
static noinline void do_fault_error(struct pt_regs *regs, vm_fault_t fault)
{
int si_code;
......@@ -518,7 +517,7 @@ void do_protection_exception(struct pt_regs *regs)
fault = do_exception(regs, access);
}
if (unlikely(fault))
do_fault_error(regs, access, fault);
do_fault_error(regs, fault);
}
NOKPROBE_SYMBOL(do_protection_exception);
......@@ -530,7 +529,7 @@ void do_dat_exception(struct pt_regs *regs)
access = VM_ACCESS_FLAGS;
fault = do_exception(regs, access);
if (unlikely(fault))
do_fault_error(regs, access, fault);
do_fault_error(regs, fault);
}
NOKPROBE_SYMBOL(do_dat_exception);
......@@ -805,7 +804,7 @@ void do_secure_storage_access(struct pt_regs *regs)
addr = __gmap_translate(gmap, addr);
mmap_read_unlock(mm);
if (IS_ERR_VALUE(addr)) {
do_fault_error(regs, VM_ACCESS_FLAGS, VM_FAULT_BADMAP);
do_fault_error(regs, VM_FAULT_BADMAP);
break;
}
fallthrough;
......@@ -815,7 +814,7 @@ void do_secure_storage_access(struct pt_regs *regs)
vma = find_vma(mm, addr);
if (!vma) {
mmap_read_unlock(mm);
do_fault_error(regs, VM_READ | VM_WRITE, VM_FAULT_BADMAP);
do_fault_error(regs, VM_FAULT_BADMAP);
break;
}
page = follow_page(vma, addr, FOLL_WRITE | FOLL_GET);
......@@ -838,7 +837,7 @@ void do_secure_storage_access(struct pt_regs *regs)
BUG();
break;
default:
do_fault_error(regs, VM_READ | VM_WRITE, VM_FAULT_BADMAP);
do_fault_error(regs, VM_FAULT_BADMAP);
WARN_ON_ONCE(1);
}
}
......@@ -850,7 +849,7 @@ void do_non_secure_storage_access(struct pt_regs *regs)
struct gmap *gmap = (struct gmap *)S390_lowcore.gmap;
if (get_fault_type(regs) != GMAP_FAULT) {
do_fault_error(regs, VM_READ | VM_WRITE, VM_FAULT_BADMAP);
do_fault_error(regs, VM_FAULT_BADMAP);
WARN_ON_ONCE(1);
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