From: Gao Xiang <hsiangkao@linux.alibaba.com>
To: Yifan Zhao <zhaoyifan28@huawei.com>, linux-erofs@lists.ozlabs.org
Cc: zhukeqian1@huawei.com
Subject: Re: [PATCH v2 1/2] erofs-utils: lib: don't abort on compression fallback
Date: Tue, 23 Jun 2026 11:20:11 +0800 [thread overview]
Message-ID: <9d5e66e2-189b-484b-8ad7-1fd890c4668b@linux.alibaba.com> (raw)
In-Reply-To: <20260623025334.1049210-1-zhaoyifan28@huawei.com>
On 2026/6/23 10:53, Yifan Zhao wrote:
> File-level compression fallback is control flow, not a real error.
> Return an erofs-specific status code for it instead of overloading
> -ENOSPC, which can also report real space failures.
>
> Keep the global compression context reusable for that fallback while
> preserving the fatal state for real errors.
>
> Fixes: a729584ef975 ("erofs-utils: mkfs: avoid hanging if fragment is on and tmpdir is full")
> Reported-by: Bastian Schmitz <bastian.schmitz@vorwerk.de>
> Closes: https://github.com/erofs/erofs-utils/issues/50
> Assisted-by: Codex:GPT-5.5
> Signed-off-by: Yifan Zhao <zhaoyifan28@huawei.com>
> ---
> include/erofs/err.h | 1 +
> lib/compress.c | 10 +++++++---
> lib/inode.c | 6 +++---
> 3 files changed, 11 insertions(+), 6 deletions(-)
>
> diff --git a/include/erofs/err.h b/include/erofs/err.h
> index 7dacc91..ef882c9 100644
> --- a/include/erofs/err.h
> +++ b/include/erofs/err.h
> @@ -29,6 +29,7 @@ static inline const char *erofs_strerror(int err)
> }
>
> #define MAX_ERRNO (4095)
> +#define EROFS_ERRNO_COMPR_FALLBACK (MAX_ERRNO + 1)
hmmm, the naming is not quite good, I will think out a
new name and manually change it.
next prev parent reply other threads:[~2026-06-23 3:20 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-23 2:53 [PATCH v2 1/2] erofs-utils: lib: don't abort on compression fallback Yifan Zhao
2026-06-23 2:53 ` [PATCH v2 2/2] erofs-utils: lib: honor rebuild whiteouts for recreated dirs Yifan Zhao
2026-06-23 3:20 ` Gao Xiang [this message]
2026-06-23 6:46 ` [PATCH v3 1/2] erofs-utils: lib: don't abort on compression fallback Gao Xiang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9d5e66e2-189b-484b-8ad7-1fd890c4668b@linux.alibaba.com \
--to=hsiangkao@linux.alibaba.com \
--cc=linux-erofs@lists.ozlabs.org \
--cc=zhaoyifan28@huawei.com \
--cc=zhukeqian1@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox