summaryrefslogtreecommitdiffstats
path: root/lib/Kconfig
diff options
context:
space:
mode:
authorNick Terrell <terrelln@fb.com>2020-07-30 12:08:35 -0700
committerIngo Molnar <mingo@kernel.org>2020-07-31 11:49:08 +0200
commit4963bb2b89884bbdb7e33e6a09c159551e9627aa (patch)
tree503649537075d61fddbfec3f73736d57e5c33a2e /lib/Kconfig
parent6d25a633ea68a103c7293d16eb69a7d4689075ad (diff)
downloadlinux-4963bb2b89884bbdb7e33e6a09c159551e9627aa.tar.bz2
lib: Add zstd support to decompress
- Add unzstd() and the zstd decompress interface. - Add zstd support to decompress_method(). The decompress_method() and unzstd() functions are used to decompress the initramfs and the initrd. The __decompress() function is used in the preboot environment to decompress a zstd compressed kernel. The zstd decompression function allows the input and output buffers to overlap because that is used by x86 kernel decompression. Signed-off-by: Nick Terrell <terrelln@fb.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Tested-by: Sedat Dilek <sedat.dilek@gmail.com> Reviewed-by: Kees Cook <keescook@chromium.org> Link: https://lore.kernel.org/r/20200730190841.2071656-3-nickrterrell@gmail.com
Diffstat (limited to 'lib/Kconfig')
-rw-r--r--lib/Kconfig4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Kconfig b/lib/Kconfig
index df3f3da95990..a5d6f23c4cab 100644
--- a/lib/Kconfig
+++ b/lib/Kconfig
@@ -342,6 +342,10 @@ config DECOMPRESS_LZ4
select LZ4_DECOMPRESS
tristate
+config DECOMPRESS_ZSTD
+ select ZSTD_DECOMPRESS
+ tristate
+
#
# Generic allocator support is selected if needed
#