f2fs: push some variables to debug part
Some, counters are needed only for the statistical information while debugging. So, those can be controlled using CONFIG_F2FS_STAT_FS, pushing the usage for few variables under this flag. Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com> Signed-off-by: Amit Sahrawat <a.sahrawat@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
This commit is contained in:
parent
a9841c4dbb
commit
35b09d82c3
5 changed files with 21 additions and 2 deletions
|
|
@ -610,7 +610,10 @@ static void allocate_segment_by_default(struct f2fs_sb_info *sbi,
|
|||
else
|
||||
new_curseg(sbi, type, false);
|
||||
out:
|
||||
#ifdef CONFIG_F2FS_STAT_FS
|
||||
sbi->segment_count[curseg->alloc_type]++;
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
|
||||
void allocate_new_segments(struct f2fs_sb_info *sbi)
|
||||
|
|
@ -846,7 +849,9 @@ static void do_write_page(struct f2fs_sb_info *sbi, struct page *page,
|
|||
|
||||
mutex_lock(&sit_i->sentry_lock);
|
||||
__refresh_next_blkoff(sbi, curseg);
|
||||
#ifdef CONFIG_F2FS_STAT_FS
|
||||
sbi->block_count[curseg->alloc_type]++;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* SIT information should be updated before segment allocation,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue