[patch 37/56] XFS: set b_error from bio error in xfs_buf_bio_end_io

From: Greg KH
Date: Tue Feb 10 2009 - 19:41:31 EST


2.6.27-stable review patch. If anyone has any objections, please let us know.
------------------

From: Lachlan McIlroy <lachlan@xxxxxxxxxxxxxxxxxxxxxxxxx>

commit cfbe52672fbc6f333892e8dde82c35e0a76aa5f5 upstream.

Preserve any error returned by the bio layer.

Reviewed-by: Eric Sandeen <sandeen@xxxxxxxxxxx>
Reviewed-by: Tim Shimmin <tes@xxxxxxx>
Signed-off-by: Lachlan McIlroy <lachlan@xxxxxxx>
Cc: Neil Brown <neilb@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx>

---
fs/xfs/linux-2.6/xfs_buf.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

--- a/fs/xfs/linux-2.6/xfs_buf.c
+++ b/fs/xfs/linux-2.6/xfs_buf.c
@@ -1114,8 +1114,7 @@ xfs_buf_bio_end_io(
unsigned int blocksize = bp->b_target->bt_bsize;
struct bio_vec *bvec = bio->bi_io_vec + bio->bi_vcnt - 1;

- if (!test_bit(BIO_UPTODATE, &bio->bi_flags))
- bp->b_error = EIO;
+ xfs_buf_ioerror(bp, -error);

do {
struct page *page = bvec->bv_page;

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/