From: Robin Dong <sanbai@xxxxxxxxxx> The argument "save_blocks_count" and the block bitmap has the unit of cluster, so it don't need EXT2FS_C2B to convert argument "i". This patch is based on "next" branch of e2fsprogs. Signed-off-by: Robin Dong <sanbai@xxxxxxxxxx> Cc: Ted Ts'o <tytso@xxxxxxx> --- e2fsck/pass5.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/e2fsck/pass5.c b/e2fsck/pass5.c index f9d746c..bb2a4dd 100644 --- a/e2fsck/pass5.c +++ b/e2fsck/pass5.c @@ -763,12 +763,10 @@ static void check_block_end(e2fsck_t ctx) /* Protect loop from wrap-around if end is maxed */ for (i = save_blocks_count + 1; i <= end && i > save_blocks_count; i++) { - if (!ext2fs_test_block_bitmap2(fs->block_map, - EXT2FS_C2B(fs, i))) { + if (!ext2fs_test_block_bitmap2(fs->block_map, i)) { if (fix_problem(ctx, PR_5_BLOCK_BMAP_PADDING, &pctx)) { for (; i <= end; i++) - ext2fs_mark_block_bitmap2(fs->block_map, - EXT2FS_C2B(fs, i)); + ext2fs_mark_block_bitmap2(fs->block_map, i); ext2fs_mark_bb_dirty(fs); } else ext2fs_unmark_valid(fs); -- 1.7.3.2 -- To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html