@@ -660,7 +660,7 @@ dump:
return 0;
}
-static bool is_sit_bitmap_set(struct f2fs_sb_info *sbi, u32 blk_addr)
+bool is_sit_bitmap_set(struct f2fs_sb_info *sbi, u32 blk_addr)
{
struct seg_entry *se;
u32 offset;
@@ -633,18 +633,6 @@ err:
return -EINVAL;
}
-static bool is_sit_bitmap_set(struct f2fs_sb_info *sbi, u32 blk_addr)
-{
- struct seg_entry *se;
- u32 offset;
-
- se = get_seg_entry(sbi, GET_SEGNO(sbi, blk_addr));
- offset = OFFSET_IN_SEG(sbi, blk_addr);
-
- return f2fs_test_bit(offset,
- (const char *)se->cur_valid_map) != 0;
-}
-
int fsck_chk_root_inode(struct f2fs_sb_info *sbi)
{
struct f2fs_node *node_blk;
@@ -281,7 +281,7 @@ extern int dump_node(struct f2fs_sb_info *, nid_t, int, char *, int, int);
extern int dump_info_from_blkaddr(struct f2fs_sb_info *, u32);
extern unsigned int start_bidx_of_node(unsigned int, struct f2fs_node *);
extern void dump_node_scan_disk(struct f2fs_sb_info *sbi, nid_t nid);
-
+extern bool is_sit_bitmap_set(struct f2fs_sb_info *sbi, u32 blk_addr);
/* defrag.c */
int f2fs_defragment(struct f2fs_sb_info *, u64, u64, u64, int);
Remove redundant function definition of is_sit_bitmap_set() and export it. Signed-off-by: Sheng Yong <shengyong@oppo.com> --- fsck/dump.c | 2 +- fsck/fsck.c | 12 ------------ fsck/fsck.h | 2 +- 3 files changed, 2 insertions(+), 14 deletions(-)