riscv: make image compression configurable
authorEmil Renner Berthing <emil.renner.berthing@canonical.com>
Sat, 4 May 2024 19:34:38 +0000 (21:34 +0200)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 22 May 2024 23:12:44 +0000 (16:12 -0700)
commite79dfcbfb902a99268cc8022031461da7a8e2bc8
tree3f251d982ad4fccebe2747932afac34ce1149a2d
parent0bfbc914d9433d8ac2763a9ce99ce7721ee5c8e0
riscv: make image compression configurable

Previously the build process would always set KBUILD_IMAGE to the
uncompressed Image file (unless XIP_KERNEL or EFI_ZBOOT was enabled) and
unconditionally compress it into Image.gz. However there are already
build targets for Image.bz2, Image.lz4, Image.lzma, Image.lzo and
Image.zstd, so let's make use of those, make the compression method
configurable and set KBUILD_IMAGE accordingly so that targets like
'make install' and 'make bindeb-pkg' will use the chosen image.

Tested-by: Björn Töpel <bjorn@rivosinc.com>
Signed-off-by: Emil Renner Berthing <emil.renner.berthing@canonical.com>
Reviewed-by: Nicolas Schier <n.schier@avm.de>
Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>
Link: https://lore.kernel.org/r/20240504193446.196886-2-emil.renner.berthing@canonical.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/Kconfig
arch/riscv/Makefile
arch/riscv/boot/install.sh