Re: [RFC PATCH v5] f2fs: support data compression

From: Geert Uytterhoeven
Date: Thu Dec 19 2019 - 05:18:23 EST


Hi,

On Mon, Dec 16, 2019 at 7:29 AM Chao Yu <yuchao0@xxxxxxxxxx> wrote:
> This patch tries to support compression in f2fs.

> --- a/fs/f2fs/Kconfig
> +++ b/fs/f2fs/Kconfig
> @@ -92,3 +92,26 @@ config F2FS_FAULT_INJECTION
> Test F2FS to inject faults such as ENOMEM, ENOSPC, and so on.
>
> If unsure, say N.
> +
> +config F2FS_FS_COMPRESSION
> + bool "F2FS compression feature"
> + depends on F2FS_FS
> + help
> + Enable filesystem-level compression on f2fs regular files,
> + multiple back-end compression algorithms are supported.
> +
> +config F2FS_FS_LZO
> + bool "LZO compression support" if F2FS_FS_COMPRESSION

This should depend on F2FS_FS_COMPRESSION, instead of just hiding
the question, to avoid the option always being enabled when
F2FS_FS_COMPRESSION is not set:

bool "LZO compression support"
depends on F2FS_FS_COMPRESSION

> + select LZO_COMPRESS
> + select LZO_DECOMPRESS
> + default y
> + help
> + Support LZO compress algorithm, if unsure, say Y.
> +
> +config F2FS_FS_LZ4
> + bool "LZ4 compression support" if F2FS_FS_COMPRESSION

Likewise.

> + select LZ4_COMPRESS
> + select LZ4_DECOMPRESS
> + default y
> + help
> + Support LZ4 compress algorithm, if unsure, say Y.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds