Re: [RFC PATCH 6/6] btrfs: zlib: add support for zlib-deflate through acomp

Herbert Xu
2025-05-07T02:24:05Z

On Tue, May 06, 2025 at 04:38:11PM +0100, Cabiddu, Giovanni wrote:
>
> > We'd have to enhance the compression format specifier to make it
> > configurable in the sense: if accelerator is available use it, otherwise
> > do CPU and synchronous compression.
> For usability, wouldn't it be better to have a transparent solution? If
> an accelerator is present, use it, rather than having a configuration
> knob.

If you go through the Crypto API you won't need to add a new knob
at all.

The Crypto API is already configurable and comes with a knob
pre-installed. Just download crconf and you can configure which
algorithm will be used by default:

https://git.code.sf.net/p/crconf/code

Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt