On 2020/12/28 18:51, Gao Xiang wrote:
> From: Gao Xiang <hsiang...@aol.com>
>
> "failed to find [%s] in canned fs_config" was observed by using
> "--fs-config-file" option as reported by Yue Hu [1].
>
> The root cause was that the mountpoint prefix to subdirectories is
> also needed if "--mount-point" presents. However, such prefix cannot
> be added by just using erofs_fspath().
>
> One exception is that the root directory itself needs to be handled
> specially for canned fs_config. For such case, the prefix of the root
> directory has to be dropped instead.
>
> [1] https://lkml.kernel.org/r/20201222020430.12512-1-zbest...@gmail.com
>
> Link: https://lore.kernel.org/r/20201226062736.29920-1-hsiang...@aol.com
> Fixes: 8a9e8046f170 ("AOSP: erofs-utils: add fs_config support")
> Reported-by: Yue Hu <huy...@yulong.com>
> Signed-off-by: Gao Xiang <hsiang...@aol.com>
> ---
> changes since v2:
> - fix IS_ROOT misuse reported by Jianan, very sorry about this since
> I know little about canned fs_config.
>
> (please kindly test again...)
>
> lib/inode.c | 39 +++++++++++++++++++++++++--------------
> 1 file changed, 25 insertions(+), 14 deletions(-)
>
It looks good
Reviewed-by: Li Guifu <bluce....@aliyun.com>
Thanks,