From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: Daniel Vacek <neelx@suse.com>, dsterba@suse.cz
Cc: Qu Wenruo <wqu@suse.com>, Chris Mason <clm@fb.com>,
Josef Bacik <josef@toxicpanda.com>,
David Sterba <dsterba@suse.com>, Nick Terrell <terrelln@fb.com>,
linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] btrfs: zstd: add `zstd-fast` alias mount option for fast modes
Date: Wed, 2 Apr 2025 19:38:07 +1030 [thread overview]
Message-ID: <e3e5f96a-8b46-4e61-a66b-253d2dbe6aa4@gmx.com> (raw)
In-Reply-To: <CAPjX3Ff2nTrF6K+6Uk707WBfvgKOsDcmbSfXLeRyzWbqN7-xQw@mail.gmail.com>
在 2025/4/2 19:07, Daniel Vacek 写道:
> On Tue, 1 Apr 2025 at 00:57, David Sterba <dsterba@suse.cz> wrote:
[...]
>>>> I thought this was solid. Or would you rather bail out with -EINVAL?
>>>
>>> I prefer to bail out with -EINVAL, but it's only my personal choice.
>>
>> I tend to agree with you, the idea for the alias was based on feedback
>> that upstream zstd calls the levels fast, not by the negative numbers.
>> So I think we stick to the zstd: and zstd-fast: prefixes followed only
>> by the positive numbers.
>
> Hmm, so for zlib and zstd if the level is out of range, it's just
> clipped and not failed as invalid. I guess zstd-fast should also do
> the same to be consistent.
Or we can change the zlib/zstd level checks so that it can return
-EINVAL when invalid levels are provided.
But to avoid huge surprise, I'd recommend to add warning/error messages
first.
I'm not a huge fan when invalid values are silently clamped, even it's
just an optional level parameter.
Thanks,
Qu
>
>> We can make this change before 6.15 final so it's not in any released
>> kernel and we don't have to deal with compatibility.
>
next prev parent reply other threads:[~2025-04-02 9:08 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-31 8:23 Daniel Vacek
2025-03-31 8:49 ` Qu Wenruo
2025-03-31 10:06 ` Daniel Vacek
2025-03-31 21:14 ` Qu Wenruo
2025-03-31 22:57 ` David Sterba
2025-04-02 8:37 ` Daniel Vacek
2025-04-02 9:08 ` Qu Wenruo [this message]
2025-04-02 10:29 ` Daniel Vacek
2025-04-02 14:31 ` Daniel Vacek
2025-04-14 6:53 ` Daniel Vacek
2025-04-15 3:50 ` Qu Wenruo
2025-04-15 14:58 ` Nick Terrell
2025-04-15 16:56 ` David Sterba
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=e3e5f96a-8b46-4e61-a66b-253d2dbe6aa4@gmx.com \
--to=quwenruo.btrfs@gmx.com \
--cc=clm@fb.com \
--cc=dsterba@suse.com \
--cc=dsterba@suse.cz \
--cc=josef@toxicpanda.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=neelx@suse.com \
--cc=terrelln@fb.com \
--cc=wqu@suse.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
all inboxes | Powered by JetHome®