From ab13dc56cbf5b142b56eb8f81f909afc1332a847 Mon Sep 17 00:00:00 2001 From: Hidehiro Kawai Date: Sat, 26 Jul 2008 16:39:26 -0400 Subject: [PATCH] --- yaml --- r: 107535 b: refs/heads/master c: 9c83a923c67df311c467ec956009f0eb4019195d h: refs/heads/master i: 107533: 3ee59c85ec0c6488e3677ce7b9a3b4a6cd6cbfaa 107531: 89d63cbf2673df17f940dd5fc61f20b8a09ab548 107527: 04b3b9a926d85396941cccd7c5dfbaf4605c7492 107519: 6a6a436dcd11ecc863eb73befd8f79dd5521f40e v: v3 --- [refs] | 2 +- trunk/fs/ext4/inode.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 167f43b92b18..b3684dc02331 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 6be2ded1d7c51b39144b9f07d2c839e1bd8707f1 +refs/heads/master: 9c83a923c67df311c467ec956009f0eb4019195d diff --git a/trunk/fs/ext4/inode.c b/trunk/fs/ext4/inode.c index 9843b046c235..efe8caa3811c 100644 --- a/trunk/fs/ext4/inode.c +++ b/trunk/fs/ext4/inode.c @@ -3590,6 +3590,16 @@ static int __ext4_get_inode_loc(struct inode *inode, } if (!buffer_uptodate(bh)) { lock_buffer(bh); + + /* + * If the buffer has the write error flag, we have failed + * to write out another inode in the same block. In this + * case, we don't have to read the block because we may + * read the old inode data successfully. + */ + if (buffer_write_io_error(bh) && !buffer_uptodate(bh)) + set_buffer_uptodate(bh); + if (buffer_uptodate(bh)) { /* someone brought it uptodate while we waited */ unlock_buffer(bh);