summaryrefslogtreecommitdiffstats
path: root/lib/decompress_unzstd.c
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2023-05-17 15:19:31 +0200
committerAndrew Morton <akpm@linux-foundation.org>2023-06-10 02:44:17 +0200
commit004444486184a7222a7b4bde0c568f6da3621b25 (patch)
tree3f14660712a5d58379b4e0db0fadd80cc50b7b0b /lib/decompress_unzstd.c
parentinit: add bdev fs printk if mount_block_root failed (diff)
downloadlinux-004444486184a7222a7b4bde0c568f6da3621b25.tar.xz
linux-004444486184a7222a7b4bde0c568f6da3621b25.zip
decompressor: provide missing prototypes
The entry points for the decompressor don't always have a prototype included in the .c file: lib/decompress_inflate.c:42:17: error: no previous prototype for '__gunzip' [-Werror=missing-prototypes] lib/decompress_unxz.c:251:17: error: no previous prototype for 'unxz' [-Werror=missing-prototypes] lib/decompress_unzstd.c:331:17: error: no previous prototype for 'unzstd' [-Werror=missing-prototypes] Include the correct headers for unxz and unzstd, and mark the inflate function above as unconditionally 'static' to avoid these warnings. Link: https://lkml.kernel.org/r/20230517131936.936840-1-arnd@kernel.org Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Nick Terrell <terrelln@fb.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'lib/decompress_unzstd.c')
-rw-r--r--lib/decompress_unzstd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/decompress_unzstd.c b/lib/decompress_unzstd.c
index a512b99ae16a..bba2c0bb10cb 100644
--- a/lib/decompress_unzstd.c
+++ b/lib/decompress_unzstd.c
@@ -69,6 +69,8 @@
# define UNZSTD_PREBOOT
# include "xxhash.c"
# include "zstd/decompress_sources.h"
+#else
+#include <linux/decompress/unzstd.h>
#endif
#include <linux/decompress/mm.h>