xfs
[Top] [All Lists]

Re: [PATCH 5/5] dax: handle media errors in dax_do_io

To: Vishal Verma <vishal.l.verma@xxxxxxxxx>
Subject: Re: [PATCH 5/5] dax: handle media errors in dax_do_io
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Fri, 25 Mar 2016 03:45:49 -0700
Cc: linux-nvdimm@xxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, linux-block@xxxxxxxxxxxxxxx, xfs@xxxxxxxxxxx, linux-ext4@xxxxxxxxxxxxxxx, linux-mm@xxxxxxxxx, Matthew Wilcox <matthew.r.wilcox@xxxxxxxxx>, Ross Zwisler <ross.zwisler@xxxxxxxxxxxxxxx>, Dan Williams <dan.j.williams@xxxxxxxxx>, Dave Chinner <david@xxxxxxxxxxxxx>, Jan Kara <jack@xxxxxxx>, Jens Axboe <axboe@xxxxxx>, Al Viro <viro@xxxxxxxxxxxxxxxxxx>, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <1458861450-17705-6-git-send-email-vishal.l.verma@xxxxxxxxx>
References: <1458861450-17705-1-git-send-email-vishal.l.verma@xxxxxxxxx> <1458861450-17705-6-git-send-email-vishal.l.verma@xxxxxxxxx>
User-agent: Mutt/1.5.24 (2015-08-30)
On Thu, Mar 24, 2016 at 05:17:30PM -0600, Vishal Verma wrote:
> dax_do_io (called for read() or write() for a dax file system) may fail
> in the presence of bad blocks or media errors. Since we expect that a
> write should clear media errors on nvdimms, make dax_do_io fall back to
> the direct_IO path, which will send down a bio to the driver, which can
> then attempt to clear the error.

Leave the fallback on -EIO to the callers please.  They generally call
__blockdev_direct_IO anyway, so it should actually become simpler that
way.

<Prev in Thread] Current Thread [Next in Thread>