Linux-EROFS Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode
@ 2023-09-15  8:27 Jingbo Xu
  2023-09-15  8:55 ` [External] " Jia Zhu via Linux-erofs
  2023-09-15  9:14 ` Gao Xiang
  0 siblings, 2 replies; 3+ messages in thread
From: Jingbo Xu @ 2023-09-15  8:27 UTC (permalink / raw)
  To: xiang, chao, linux-erofs; +Cc: huyue2

The device tag is not required in flatdev mode, and thus relax this
constraint in flatdev mode.

Signed-off-by: Jingbo Xu <jefflexu@linux.alibaba.com>
---
Sorry I forget to cc linux-erofs@lists.ozlabs.org in the former patch.
---
 fs/erofs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/erofs/super.c b/fs/erofs/super.c
index 44a24d573f1f..3700af9ee173 100644
--- a/fs/erofs/super.c
+++ b/fs/erofs/super.c
@@ -235,7 +235,7 @@ static int erofs_init_device(struct erofs_buf *buf, struct super_block *sb,
 		return PTR_ERR(ptr);
 	dis = ptr + erofs_blkoff(sb, *pos);
 
-	if (!dif->path) {
+	if (!sbi->devs->flatdev && !dif->path) {
 		if (!dis->tag[0]) {
 			erofs_err(sb, "empty device tag @ pos %llu", *pos);
 			return -EINVAL;
-- 
2.19.1.6.gb485710b


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [External] [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode
  2023-09-15  8:27 [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode Jingbo Xu
@ 2023-09-15  8:55 ` Jia Zhu via Linux-erofs
  2023-09-15  9:14 ` Gao Xiang
  1 sibling, 0 replies; 3+ messages in thread
From: Jia Zhu via Linux-erofs @ 2023-09-15  8:55 UTC (permalink / raw)
  To: Jingbo Xu, xiang, chao, linux-erofs; +Cc: huyue2



在 2023/9/15 16:27, Jingbo Xu 写道:
> The device tag is not required in flatdev mode, and thus relax this
> constraint in flatdev mode.
> 
> Signed-off-by: Jingbo Xu <jefflexu@linux.alibaba.com>

LGTM
Reviewed-by: Jia Zhu <zhujia.zj@bytedance.com>

> ---
> Sorry I forget to cc linux-erofs@lists.ozlabs.org in the former patch.
> ---
>   fs/erofs/super.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/erofs/super.c b/fs/erofs/super.c
> index 44a24d573f1f..3700af9ee173 100644
> --- a/fs/erofs/super.c
> +++ b/fs/erofs/super.c
> @@ -235,7 +235,7 @@ static int erofs_init_device(struct erofs_buf *buf, struct super_block *sb,
>   		return PTR_ERR(ptr);
>   	dis = ptr + erofs_blkoff(sb, *pos);
>   
> -	if (!dif->path) {
> +	if (!sbi->devs->flatdev && !dif->path) {
>   		if (!dis->tag[0]) {
>   			erofs_err(sb, "empty device tag @ pos %llu", *pos);
>   			return -EINVAL;

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode
  2023-09-15  8:27 [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode Jingbo Xu
  2023-09-15  8:55 ` [External] " Jia Zhu via Linux-erofs
@ 2023-09-15  9:14 ` Gao Xiang
  1 sibling, 0 replies; 3+ messages in thread
From: Gao Xiang @ 2023-09-15  9:14 UTC (permalink / raw)
  To: Jingbo Xu, xiang, chao, linux-erofs; +Cc: huyue2



On 2023/9/15 16:27, Jingbo Xu wrote:
> The device tag is not required in flatdev mode, and thus relax this
> constraint in flatdev mode.
> 
> Signed-off-by: Jingbo Xu <jefflexu@linux.alibaba.com>

I tend to update the subject title and commit message as a fix:

erofs: allow empty device tags in flatdev mode

Device tags aren't actually required in flatdev mode, thus
fix mount failure due to empty device tags in flatdev mode.

Fixes: 8b465fecc35a ("erofs: support flattened block device for multi-blob images")
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Thanks,
Gao Xiang

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-09-15  9:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-15  8:27 [RESEND PATCH] erofs: relax the constraint of non-empty device tag in flatdev mode Jingbo Xu
2023-09-15  8:55 ` [External] " Jia Zhu via Linux-erofs
2023-09-15  9:14 ` Gao Xiang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox