linux-f2fs-devel.lists.sourceforge.net archive mirror
 help / color / mirror / Atom feed
* Re: [f2fs-dev] [PATCH v2] f2fs: use EINVAL for superblock with invalid magic
       [not found] <20190725030852.33161-1-icenowy@aosc.io>
@ 2019-07-25  3:15 ` Chao Yu
  0 siblings, 0 replies; only message in thread
From: Chao Yu @ 2019-07-25  3:15 UTC (permalink / raw)
  To: Icenowy Zheng, Jaegeuk Kim; +Cc: linux-kernel, linux-f2fs-devel

On 2019/7/25 11:08, Icenowy Zheng wrote:
> The kernel mount_block_root() function expects -EACESS or -EINVAL for a
> unmountable filesystem when trying to mount the root with different
> filesystem types.
> 
> However, in 5.3-rc1 the behavior when F2FS code cannot find valid block
> changed to return -EFSCORRUPTED(-EUCLEAN), and this error code makes
> mount_block_root() fail when trying to probe F2FS.
> 
> When the magic number of the superblock mismatches, it has a high
> probability that it's just not a F2FS. In this case return -EINVAL seems
> to be a better result, and this return value can make mount_block_root()
> probing work again.
> 
> Return -EINVAL when the superblock has magic mismatch, -EFSCORRUPTED in
> other cases (the magic matches but the superblock cannot be recognized).
> 
> Fixes: 10f966bbf521 ("f2fs: use generic EFSBADCRC/EFSCORRUPTED")
> Signed-off-by: Icenowy Zheng <icenowy@aosc.io>

Reviewed-by: Chao Yu <yuchao0@huawei.com>

Thanks,


_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-07-25  3:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20190725030852.33161-1-icenowy@aosc.io>
2019-07-25  3:15 ` [f2fs-dev] [PATCH v2] f2fs: use EINVAL for superblock with invalid magic Chao Yu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).