From: zhong jiang <zhongjiang@huawei.com>
To: <jack@suse.cz>, <viro@zeniv.linux.org.uk>
Cc: <zwisler@kernel.org>, <mawilcox@microsoft.com>,
<linux-fsdevel@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH] fs/dax.c: Use vmf_error() helper
Date: Sat, 29 Sep 2018 13:17:17 +0800 [thread overview]
Message-ID: <1538198237-37466-1-git-send-email-zhongjiang@huawei.com> (raw)
These codes can be replaced with new inline vmf_error().
Signed-off-by: zhong jiang <zhongjiang@huawei.com>
---
fs/dax.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index b68ce48..e732f70 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -1311,9 +1311,8 @@ static vm_fault_t dax_fault_return(int error)
{
if (error == 0)
return VM_FAULT_NOPAGE;
- if (error == -ENOMEM)
- return VM_FAULT_OOM;
- return VM_FAULT_SIGBUS;
+
+ return vmf_error(error);
}
/*
--
1.7.12.4
reply other threads:[~2018-09-29 11:56 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1538198237-37466-1-git-send-email-zhongjiang@huawei.com \
--to=zhongjiang@huawei.com \
--cc=jack@suse.cz \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mawilcox@microsoft.com \
--cc=viro@zeniv.linux.org.uk \
--cc=zwisler@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).