diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 3995e926ba3a..a4ac297e66df 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -2229,9 +2229,9 @@ static int sanity_check_raw_super(struct f2fs_sb_info *sbi, return 1; } - if (secs_per_zone > total_sections) { + if (secs_per_zone > total_sections || !secs_per_zone) { f2fs_msg(sb, KERN_INFO, - "Wrong secs_per_zone (%u > %u)", + "Wrong secs_per_zone / total_sections (%u, %u)", secs_per_zone, total_sections); return 1; }