diff mbox series

RISC-V: Add multiple compression image format.

Message ID 20191106000652.8370-1-atish.patra@wdc.com (mailing list archive)
State New, archived
Headers show
Series RISC-V: Add multiple compression image format. | expand

Commit Message

Atish Patra Nov. 6, 2019, 12:06 a.m. UTC
Currently, there is only support for .gz compression type
for generating kernel Image.

Add support for other compression methods(lzma, lz4, lzo, bzip2)
that helps in generating a even smaller kernel image. Image.gz
will still be the default compressed image.

Signed-off-by: Atish Patra <atish.patra@wdc.com>
---
 arch/riscv/boot/Makefile | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Comments

Palmer Dabbelt Nov. 6, 2019, 5:47 p.m. UTC | #1
On Tue, 05 Nov 2019 16:06:52 PST (-0800), Atish Patra wrote:
> Currently, there is only support for .gz compression type
> for generating kernel Image.
>
> Add support for other compression methods(lzma, lz4, lzo, bzip2)
> that helps in generating a even smaller kernel image. Image.gz
> will still be the default compressed image.
>
> Signed-off-by: Atish Patra <atish.patra@wdc.com>
> ---
>  arch/riscv/boot/Makefile | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
>
> diff --git a/arch/riscv/boot/Makefile b/arch/riscv/boot/Makefile
> index 0990a9fdbe5d..88356650c992 100644
> --- a/arch/riscv/boot/Makefile
> +++ b/arch/riscv/boot/Makefile
> @@ -24,6 +24,18 @@ $(obj)/Image: vmlinux FORCE
>  $(obj)/Image.gz: $(obj)/Image FORCE
>  	$(call if_changed,gzip)
>
> +$(obj)/Image.bz2: $(obj)/Image FORCE
> +	$(call if_changed,bzip2)
> +
> +$(obj)/Image.lz4: $(obj)/Image FORCE
> +	$(call if_changed,lz4)
> +
> +$(obj)/Image.lzma: $(obj)/Image FORCE
> +	$(call if_changed,lzma)
> +
> +$(obj)/Image.lzo: $(obj)/Image FORCE
> +	$(call if_changed,lzo)
> +
>  install:
>  	$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
>  	$(obj)/Image System.map "$(INSTALL_PATH)"

Reviewed-by: Palmer Dabbelt <palmer@dabbelt.com>
Paul Walmsley Nov. 12, 2019, 7:35 p.m. UTC | #2
On Tue, 5 Nov 2019, Atish Patra wrote:

> Currently, there is only support for .gz compression type
> for generating kernel Image.
> 
> Add support for other compression methods(lzma, lz4, lzo, bzip2)
> that helps in generating a even smaller kernel image. Image.gz
> will still be the default compressed image.
> 
> Signed-off-by: Atish Patra <atish.patra@wdc.com>

Thanks, queued for v5.5-rc1.


- Paul
diff mbox series

Patch

diff --git a/arch/riscv/boot/Makefile b/arch/riscv/boot/Makefile
index 0990a9fdbe5d..88356650c992 100644
--- a/arch/riscv/boot/Makefile
+++ b/arch/riscv/boot/Makefile
@@ -24,6 +24,18 @@  $(obj)/Image: vmlinux FORCE
 $(obj)/Image.gz: $(obj)/Image FORCE
 	$(call if_changed,gzip)
 
+$(obj)/Image.bz2: $(obj)/Image FORCE
+	$(call if_changed,bzip2)
+
+$(obj)/Image.lz4: $(obj)/Image FORCE
+	$(call if_changed,lz4)
+
+$(obj)/Image.lzma: $(obj)/Image FORCE
+	$(call if_changed,lzma)
+
+$(obj)/Image.lzo: $(obj)/Image FORCE
+	$(call if_changed,lzo)
+
 install:
 	$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
 	$(obj)/Image System.map "$(INSTALL_PATH)"