summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--e2fsck/pass1.c10
-rw-r--r--e2fsck/super.c4
-rw-r--r--lib/ext2fs/alloc_tables.c14
-rw-r--r--lib/ext2fs/check_desc.c4
-rw-r--r--misc/dumpe2fs.c4
-rw-r--r--misc/tune2fs.c2
6 files changed, 19 insertions, 19 deletions
diff --git a/e2fsck/pass1.c b/e2fsck/pass1.c
index 567d4074..09ff1d06 100644
--- a/e2fsck/pass1.c
+++ b/e2fsck/pass1.c
@@ -2401,14 +2401,14 @@ static void new_table_block(e2fsck_t ctx, blk_t first_block, int group,
if (is_flexbg) {
flexbg_size = 1 << fs->super->s_log_groups_per_flex;
flexbg = group / flexbg_size;
- first_block = ext2fs_group_first_block(fs,
- flexbg_size * flexbg);
+ first_block = ext2fs_group_first_block2(fs,
+ flexbg_size * flexbg);
last_grp = group | (flexbg_size - 1);
if (last_grp > fs->group_desc_count)
last_grp = fs->group_desc_count;
- last_block = ext2fs_group_last_block(fs, last_grp);
+ last_block = ext2fs_group_last_block2(fs, last_grp);
} else
- last_block = ext2fs_group_last_block(fs, group);
+ last_block = ext2fs_group_last_block2(fs, group);
pctx.errcode = ext2fs_get_free_blocks2(fs, first_block, last_block,
num, ctx->block_found_map,
new_block);
@@ -2472,7 +2472,7 @@ static void handle_fs_bad_blocks(e2fsck_t ctx)
blk64_t new_blk;
for (i = 0; i < fs->group_desc_count; i++) {
- first_block = ext2fs_group_first_block(fs, i);
+ first_block = ext2fs_group_first_block2(fs, i);
if (ctx->invalid_block_bitmap_flag[i]) {
new_blk = ext2fs_block_bitmap_loc(fs, i);
diff --git a/e2fsck/super.c b/e2fsck/super.c
index 3ae2a41b..c8c44029 100644
--- a/e2fsck/super.c
+++ b/e2fsck/super.c
@@ -591,8 +591,8 @@ void check_super_block(e2fsck_t ctx)
if (!EXT2_HAS_INCOMPAT_FEATURE(fs->super,
EXT4_FEATURE_INCOMPAT_FLEX_BG)) {
- first_block = ext2fs_group_first_block(fs, i);
- last_block = ext2fs_group_last_block(fs, i);
+ first_block = ext2fs_group_first_block2(fs, i);
+ last_block = ext2fs_group_last_block2(fs, i);
}
if ((ext2fs_block_bitmap_loc(fs, i) < first_block) ||
diff --git a/lib/ext2fs/alloc_tables.c b/lib/ext2fs/alloc_tables.c
index e104abc4..44716652 100644
--- a/lib/ext2fs/alloc_tables.c
+++ b/lib/ext2fs/alloc_tables.c
@@ -61,11 +61,11 @@ static blk_t flexbg_offset(ext2_filsys fs, dgrp_t group, blk64_t start_blk,
return start_blk + elem_size;
}
- start_blk = ext2fs_group_first_block(fs, flexbg_size * flexbg);
+ start_blk = ext2fs_group_first_block2(fs, flexbg_size * flexbg);
last_grp = group | (flexbg_size - 1);
if (last_grp > fs->group_desc_count)
last_grp = fs->group_desc_count;
- last_blk = ext2fs_group_last_block(fs, last_grp);
+ last_blk = ext2fs_group_last_block2(fs, last_grp);
/* Find the first available block */
if (ext2fs_get_free_blocks(fs, start_blk, last_blk, 1, bmap,
@@ -87,8 +87,8 @@ errcode_t ext2fs_allocate_group_table(ext2_filsys fs, dgrp_t group,
dgrp_t last_grp = 0;
int j, rem_grps = 0, flexbg_size = 0;
- group_blk = ext2fs_group_first_block(fs, group);
- last_blk = ext2fs_group_last_block(fs, group);
+ group_blk = ext2fs_group_first_block2(fs, group);
+ last_blk = ext2fs_group_last_block2(fs, group);
if (!bmap)
bmap = fs->block_map;
@@ -126,7 +126,7 @@ errcode_t ext2fs_allocate_group_table(ext2_filsys fs, dgrp_t group,
prev_block = ext2fs_block_bitmap_loc(fs, group - 1);
start_blk = flexbg_offset(fs, group, prev_block, bmap,
0, rem_grps, 1);
- last_blk = ext2fs_group_last_block(fs, last_grp);
+ last_blk = ext2fs_group_last_block2(fs, last_grp);
}
if (!ext2fs_block_bitmap_loc(fs, group)) {
@@ -154,7 +154,7 @@ errcode_t ext2fs_allocate_group_table(ext2_filsys fs, dgrp_t group,
prev_block = ext2fs_inode_bitmap_loc(fs, group - 1);
start_blk = flexbg_offset(fs, group, prev_block, bmap,
flexbg_size, rem_grps, 1);
- last_blk = ext2fs_group_last_block(fs, last_grp);
+ last_blk = ext2fs_group_last_block2(fs, last_grp);
}
if (!ext2fs_inode_bitmap_loc(fs, group)) {
@@ -188,7 +188,7 @@ errcode_t ext2fs_allocate_group_table(ext2_filsys fs, dgrp_t group,
fs->inode_blocks_per_group *
rem_grps,
fs->inode_blocks_per_group);
- last_blk = ext2fs_group_last_block(fs, last_grp);
+ last_blk = ext2fs_group_last_block2(fs, last_grp);
}
if (!ext2fs_inode_table_loc(fs, group)) {
diff --git a/lib/ext2fs/check_desc.c b/lib/ext2fs/check_desc.c
index 321bf747..61a1de6e 100644
--- a/lib/ext2fs/check_desc.c
+++ b/lib/ext2fs/check_desc.c
@@ -51,8 +51,8 @@ errcode_t ext2fs_check_desc(ext2_filsys fs)
for (i = 0; i < fs->group_desc_count; i++) {
if (!EXT2_HAS_INCOMPAT_FEATURE(fs->super,
EXT4_FEATURE_INCOMPAT_FLEX_BG)) {
- first_block = ext2fs_group_first_block(fs, i);
- last_block = ext2fs_group_last_block(fs, i);
+ first_block = ext2fs_group_first_block2(fs, i);
+ last_block = ext2fs_group_last_block2(fs, i);
if (i == (fs->group_desc_count - 1))
last_block = ext2fs_blocks_count(fs->super)-1;
}
diff --git a/misc/dumpe2fs.c b/misc/dumpe2fs.c
index 298dbb24..0c280383 100644
--- a/misc/dumpe2fs.c
+++ b/misc/dumpe2fs.c
@@ -159,8 +159,8 @@ static void list_desc (ext2_filsys fs)
else
old_desc_blocks = fs->desc_blocks;
for (i = 0; i < fs->group_desc_count; i++) {
- first_block = ext2fs_group_first_block(fs, i);
- last_block = ext2fs_group_last_block(fs, i);
+ first_block = ext2fs_group_first_block2(fs, i);
+ last_block = ext2fs_group_last_block2(fs, i);
ext2fs_super_and_bgd_loc(fs, i, &super_blk,
&old_desc_blk, &new_desc_blk, 0);
diff --git a/misc/tune2fs.c b/misc/tune2fs.c
index 70bc75ee..847b3e2c 100644
--- a/misc/tune2fs.c
+++ b/misc/tune2fs.c
@@ -1069,7 +1069,7 @@ static int move_block(ext2_filsys fs, ext2fs_block_bitmap bmap)
* fail
*/
group = ext2fs_group_of_blk(fs, blk);
- goal = ext2fs_group_first_block(fs, group);
+ goal = ext2fs_group_first_block2(fs, group);
meta_data = 1;
} else {