[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190822082617.19180-2-dongyangli@ddn.com>
Date: Thu, 22 Aug 2019 08:26:49 +0000
From: Dongyang Li <dongyangli@....com>
To: "linux-ext4@...r.kernel.org" <linux-ext4@...r.kernel.org>
CC: "adilger@...ger.ca" <adilger@...ger.ca>
Subject: [PATCH v2 2/4] mke2fs: fix setting bad blocks in the block bitmap
We mark the bad blocks as used on fs->block_map
before allocating group tables.
Don't translate the block number to cluster number
when doing this, the fs->block_map is still a
block-granularity allocation map, it will be coverted
later by ext2fs_convert_subcluster_bitmap().
Signed-off-by: Li Dongyang <dongyangli@....com>
---
misc/mke2fs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/misc/mke2fs.c b/misc/mke2fs.c
index d7cf257e..30e353d3 100644
--- a/misc/mke2fs.c
+++ b/misc/mke2fs.c
@@ -344,7 +344,7 @@ _("Warning: the backup superblock/group descriptors at block %u contain\n"
exit(1);
}
while (ext2fs_badblocks_list_iterate(bb_iter, &blk))
- ext2fs_mark_block_bitmap2(fs->block_map, EXT2FS_B2C(fs, blk));
+ ext2fs_mark_block_bitmap2(fs->block_map, blk);
ext2fs_badblocks_list_iterate_end(bb_iter);
}
--
2.22.1
Powered by blists - more mailing lists