From: Matthew Wilcox <willy@linux.intel.com>
To: Ross Zwisler <ross.zwisler@linux.intel.com>
Cc: Theodore Ts'o <tytso@mit.edu>,
linux-nvdimm@lists.01.org, linux-kernel@vger.kernel.org,
xfs@oss.sgi.com, Andreas Dilger <adilger.kernel@dilger.ca>,
Alexander Viro <viro@zeniv.linux.org.uk>,
Jan Kara <jack@suse.com>,
linux-fsdevel@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
linux-ext4@vger.kernel.org,
Dan Williams <dan.j.williams@intel.com>
Subject: Re: [RFC PATCH] dax, ext2, ext4, XFS: fix data corruption race
Date: Fri, 22 Jan 2016 21:01:02 -0500 [thread overview]
Message-ID: <20160123020102.GG2948@linux.intel.com> (raw)
In-Reply-To: <1453503971-5319-1-git-send-email-ross.zwisler@linux.intel.com>
On Fri, Jan 22, 2016 at 04:06:11PM -0700, Ross Zwisler wrote:
> +++ b/fs/block_dev.c
> @@ -1733,13 +1733,28 @@ static const struct address_space_operations def_blk_aops = {
> */
> static int blkdev_dax_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
> {
> - return __dax_fault(vma, vmf, blkdev_get_block, NULL);
> + int ret;
> +
> + ret = __dax_fault(vma, vmf, blkdev_get_block, NULL, false);
> +
> + if (WARN_ON_ONCE(ret == -EAGAIN))
> + ret = VM_FAULT_SIGBUS;
> +
> + return ret;
> }
Let's not mix up -E returns and VM_FAULT returns. We already have a
perfectly good VM_FAULT return value -- VM_FAULT_RETRY.
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2016-01-23 2:01 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-22 23:06 [RFC PATCH] dax, ext2, ext4, XFS: fix data corruption race Ross Zwisler
2016-01-23 2:01 ` Matthew Wilcox [this message]
2016-01-24 22:01 ` Dave Chinner
2016-01-25 13:59 ` Jan Kara
2016-01-26 12:48 ` Matthew Wilcox
2016-01-26 13:05 ` Jan Kara
2016-01-26 14:47 ` Matthew Wilcox
2016-01-25 20:46 ` Matthew Wilcox
2016-01-26 8:46 ` Jan Kara
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=20160123020102.GG2948@linux.intel.com \
--to=willy@linux.intel.com \
--cc=adilger.kernel@dilger.ca \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=jack@suse.com \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvdimm@lists.01.org \
--cc=ross.zwisler@linux.intel.com \
--cc=tytso@mit.edu \
--cc=viro@zeniv.linux.org.uk \
--cc=xfs@oss.sgi.com \
/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).