Skip to content

Commit

Permalink
f2fs: clean up argument of recover_data
Browse files Browse the repository at this point in the history
In recover_data, value of argument 'type' will be CURSEG_WARM_NODE all
the time, remove it for cleanup.

Signed-off-by: Chao Yu <[email protected]>
Signed-off-by: Jaegeuk Kim <[email protected]>
  • Loading branch information
chaseyu authored and Jaegeuk Kim committed Dec 4, 2015
1 parent 855639d commit b7973f2
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions fs/f2fs/recovery.c
Original file line number Diff line number Diff line change
Expand Up @@ -488,8 +488,7 @@ static int do_recover_data(struct f2fs_sb_info *sbi, struct inode *inode,
return err;
}

static int recover_data(struct f2fs_sb_info *sbi,
struct list_head *head, int type)
static int recover_data(struct f2fs_sb_info *sbi, struct list_head *head)
{
unsigned long long cp_ver = cur_cp_version(F2FS_CKPT(sbi));
struct curseg_info *curseg;
Expand All @@ -498,7 +497,7 @@ static int recover_data(struct f2fs_sb_info *sbi,
block_t blkaddr;

/* get node pages in the current segment */
curseg = CURSEG_I(sbi, type);
curseg = CURSEG_I(sbi, CURSEG_WARM_NODE);
blkaddr = NEXT_FREE_BLKADDR(sbi, curseg);

while (1) {
Expand Down Expand Up @@ -585,7 +584,7 @@ int recover_fsync_data(struct f2fs_sb_info *sbi)
need_writecp = true;

/* step #2: recover data */
err = recover_data(sbi, &inode_list, CURSEG_WARM_NODE);
err = recover_data(sbi, &inode_list);
if (!err)
f2fs_bug_on(sbi, !list_empty(&inode_list));
out:
Expand Down

0 comments on commit b7973f2

Please sign in to comment.