Re: [PATCH] MIPS: add U-boot uImage build target to arch Makefile

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, Sergey

On Mon, Jan 17, 2011 at 10:43 PM, Sergey Kvachonok <ravenexp@xxxxxxxxx> wrote:
[...]
>>
>> Perhaps add more compression algos support and make them configurable
>> will be better. lzma/xz has higher compression rate, lzo has faster
>> decompression speed. and bzip2 is between lzo and gzip.
>>
>
> Ok, I'll try to make compression algo into Kconfig option then.

Just a friendly reminder: no need to add the algo options in Kconfig
for we already have them in init/Kconfig, you can search LZMA, BZIP2
... there.

With "make menuconfig", you can find them like this:

$ make menuconfig

General setup  --->
Kernel compression mode (LZMA)  --->

and then, like the Makefile of vmlinuz under
arch/mips/boot/compressed/, you can simply use the following method to
choose the compression tools:

tool_$(CONFIG_KERNEL_GZIP)    = gzip
tool_$(CONFIG_KERNEL_BZIP2)   = bzip2
tool_$(CONFIG_KERNEL_LZMA)    = lzma
tool_$(CONFIG_KERNEL_LZO)     = lzo

But to avoid adding this again, we can simply share this for uImage
and move the content from arch/mips/boot/u-boot/Makefile to
arch/mips/boot/compressed/Makefile for vmlinuz also need to compress
the vmlinux.bin, so, they can share the same vmlinux.bin.z.

and to add the uImage target, we can simply add it in
arch/mips/Makefile like this:

 # boot/compressed
-vmlinuz vmlinuz.bin vmlinuz.ecoff vmlinuz.srec: $(vmlinux-32) FORCE
+vmlinuz vmlinuz.bin vmlinuz.ecoff vmlinuz.srec uImage: $(vmlinux-32) FORCE
        $(Q)$(MAKE) $(build)=arch/mips/boot/compressed \
           VMLINUX_LOAD_ADDRESS=$(load-y) 32bit-bfd=$(32bit-bfd) $@

But we may need to check if this is compatible for the uImage target
in your old patch.

> And maybe unify with existing avr32 u-boot target, e.g. make use of
> scripts/mkuboot.sh.

Yeah, scripts/mkuboot.sh have checked the existence of the 'mkimage'
tool, so, it should be better.

> Will resubmit directly to this list when (if) it's done.

Welcome and thanks very much for your effort.

Regards,
Wu Zhangjin

>
> Regards,
> Sergey
>



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux