From b5c212374c85353a4412a08a958ecb6e0d2aa95f Mon Sep 17 00:00:00 2001 From: Souptick Joarder Date: Tue, 30 Oct 2018 15:04:35 -0700 Subject: [PATCH] fs/proc/vmcore.c: Convert to use vmf_error() This code can be replaced with vmf_error() inline function. Link: http://lkml.kernel.org/r/20180918145945.GA11392@jordon-HP-15-Notebook-PC Signed-off-by: Souptick Joarder Reviewed-by: Matthew Wilcox Cc: Alexey Dobriyan Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/proc/vmcore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/proc/vmcore.c b/fs/proc/vmcore.c index 91ae16fbd7d5..0377a104495b 100644 --- a/fs/proc/vmcore.c +++ b/fs/proc/vmcore.c @@ -423,7 +423,7 @@ static vm_fault_t mmap_vmcore_fault(struct vm_fault *vmf) if (rc < 0) { unlock_page(page); put_page(page); - return (rc == -ENOMEM) ? VM_FAULT_OOM : VM_FAULT_SIGBUS; + return vmf_error(rc); } SetPageUptodate(page); } -- 2.30.2