diff options
| author | Chao Yu <chao2.yu@samsung.com> | 2015-12-01 11:56:52 +0800 |
|---|---|---|
| committer | Mister Oyster <oysterized@gmail.com> | 2017-04-13 12:32:29 +0200 |
| commit | addb01305f6dccad99514dc5334d94668e6f0908 (patch) | |
| tree | 2617a49bfc5455686ac409ebc86b832d3aed0688 /fs/f2fs/debug.c | |
| parent | 069e02e36fa974ae49e7390629beed69cabc4d77 (diff) | |
f2fs: use sbi->blocks_per_seg to avoid unnecessary calculation
Use sbi->blocks_per_seg directly to avoid unnecessary calculation when using
1 << sbi->log_blocks_per_seg.
Signed-off-by: Chao Yu <chao2.yu@samsung.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/debug.c')
| -rw-r--r-- | fs/f2fs/debug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/debug.c b/fs/f2fs/debug.c index b0966f3b1..8ce2fe3f6 100644 --- a/fs/f2fs/debug.c +++ b/fs/f2fs/debug.c @@ -105,7 +105,7 @@ static void update_sit_info(struct f2fs_sb_info *sbi) bimodal = 0; total_vblocks = 0; - blks_per_sec = sbi->segs_per_sec * (1 << sbi->log_blocks_per_seg); + blks_per_sec = sbi->segs_per_sec * sbi->blocks_per_seg; hblks_per_sec = blks_per_sec / 2; for (segno = 0; segno < MAIN_SEGS(sbi); segno += sbi->segs_per_sec) { vblocks = get_valid_blocks(sbi, segno, sbi->segs_per_sec); |
