summaryrefslogtreecommitdiff
path: root/e2fsck
diff options
context:
space:
mode:
authorEric Sandeen <sandeen@redhat.com>2010-02-24 11:24:37 -0500
committerTheodore Ts'o <tytso@mit.edu>2010-02-24 11:24:37 -0500
commit4ffafee26cf791c0c651c08d3dcefcdd363bf127 (patch)
treefbdb76b9572e77582da23e36565acbf91a28bbc5 /e2fsck
parent53fbfb2bc3490d0ff317666322dd077c08116e0c (diff)
downloade2fsprogs-4ffafee26cf791c0c651c08d3dcefcdd363bf127.tar.gz
e2fsck: don't complain about i_size for known blocks past EOF
This is the userspace side of Jiaying's EOFBLOCKS patch. With Aneesh's patches for .33, Jiaying's patch, and this one, xfstests 013/fsstress (even with direct IO enabled) has held up through many runs. Signed-off-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'e2fsck')
-rw-r--r--e2fsck/pass1.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/e2fsck/pass1.c b/e2fsck/pass1.c
index 695abe4c..c39d8374 100644
--- a/e2fsck/pass1.c
+++ b/e2fsck/pass1.c
@@ -1990,7 +1990,8 @@ static void check_blocks(e2fsck_t ctx, struct problem_context *pctx,
/* allow allocated blocks to end of PAGE_SIZE */
(size < (__u64)pb.last_block * fs->blocksize) &&
(pb.last_block / blkpg * blkpg != pb.last_block ||
- size < (__u64)(pb.last_block & ~(blkpg-1)) *fs->blocksize))
+ size < (__u64)(pb.last_block & ~(blkpg-1)) *fs->blocksize) &&
+ !(inode->i_flags & EXT4_EOFBLOCKS_FL))
bad_size = 3;
else if (!(extent_fs && (inode->i_flags & EXT4_EXTENTS_FL)) &&
size > ext2_max_sizes[fs->super->s_log_block_size])