f2fs: introduce f2fs_<level> macros to wrap f2fs_printk()
- Add and use f2fs_<level> macros - Convert f2fs_msg to f2fs_printk - Remove level from f2fs_printk and embed the level in the format - Coalesce formats and align multi-line arguments - Remove unnecessary duplicate extern f2fs_msg f2fs.h Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Chao Yu <yuchao0@huawei.com> Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
@@ -693,9 +693,8 @@ static inline int check_block_count(struct f2fs_sb_info *sbi,
|
||||
} while (cur_pos < sbi->blocks_per_seg);
|
||||
|
||||
if (unlikely(GET_SIT_VBLOCKS(raw_sit) != valid_blocks)) {
|
||||
f2fs_msg(sbi->sb, KERN_ERR,
|
||||
"Mismatch valid blocks %d vs. %d",
|
||||
GET_SIT_VBLOCKS(raw_sit), valid_blocks);
|
||||
f2fs_err(sbi, "Mismatch valid blocks %d vs. %d",
|
||||
GET_SIT_VBLOCKS(raw_sit), valid_blocks);
|
||||
set_sbi_flag(sbi, SBI_NEED_FSCK);
|
||||
return -EINVAL;
|
||||
}
|
||||
@@ -703,9 +702,8 @@ static inline int check_block_count(struct f2fs_sb_info *sbi,
|
||||
/* check segment usage, and check boundary of a given segment number */
|
||||
if (unlikely(GET_SIT_VBLOCKS(raw_sit) > sbi->blocks_per_seg
|
||||
|| segno > TOTAL_SEGS(sbi) - 1)) {
|
||||
f2fs_msg(sbi->sb, KERN_ERR,
|
||||
"Wrong valid blocks %d or segno %u",
|
||||
GET_SIT_VBLOCKS(raw_sit), segno);
|
||||
f2fs_err(sbi, "Wrong valid blocks %d or segno %u",
|
||||
GET_SIT_VBLOCKS(raw_sit), segno);
|
||||
set_sbi_flag(sbi, SBI_NEED_FSCK);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
Reference in New Issue
Block a user