diff options
author | Dave Chinner <david@fromorbit.com> | 2016-01-11 23:04:30 +0300 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2016-01-11 23:04:30 +0300 |
commit | dde7f55bd000696acc38296c21241971e1840142 (patch) | |
tree | 79fd17020de1ea6921107ad3dbabf5eb33a88838 /fs/xfs/libxfs/xfs_inode_buf.c | |
parent | 4922be51ef1a95ca6a38694cf0cde5dd0308a24e (diff) | |
parent | 7d6a13f023567d573ac362502bb702eda716e654 (diff) | |
download | linux-dde7f55bd000696acc38296c21241971e1840142.tar.xz |
Merge branch 'xfs-misc-fixes-for-4.5-2' into for-next
Diffstat (limited to 'fs/xfs/libxfs/xfs_inode_buf.c')
-rw-r--r-- | fs/xfs/libxfs/xfs_inode_buf.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/fs/xfs/libxfs/xfs_inode_buf.c b/fs/xfs/libxfs/xfs_inode_buf.c index 1b8d98a915c4..1aabfda669b0 100644 --- a/fs/xfs/libxfs/xfs_inode_buf.c +++ b/fs/xfs/libxfs/xfs_inode_buf.c @@ -62,11 +62,14 @@ xfs_inobp_check( * has not had the inode cores stamped into it. Hence for readahead, the buffer * may be potentially invalid. * - * If the readahead buffer is invalid, we don't want to mark it with an error, - * but we do want to clear the DONE status of the buffer so that a followup read - * will re-read it from disk. This will ensure that we don't get an unnecessary - * warnings during log recovery and we don't get unnecssary panics on debug - * kernels. + * If the readahead buffer is invalid, we need to mark it with an error and + * clear the DONE status of the buffer so that a followup read will re-read it + * from disk. We don't report the error otherwise to avoid warnings during log + * recovery and we don't get unnecssary panics on debug kernels. We use EIO here + * because all we want to do is say readahead failed; there is no-one to report + * the error to, so this will distinguish it from a non-ra verifier failure. + * Changes to this readahead error behavour also need to be reflected in + * xfs_dquot_buf_readahead_verify(). */ static void xfs_inode_buf_verify( @@ -93,6 +96,7 @@ xfs_inode_buf_verify( XFS_RANDOM_ITOBP_INOTOBP))) { if (readahead) { bp->b_flags &= ~XBF_DONE; + xfs_buf_ioerror(bp, -EIO); return; } |