Re: Commit 1b7898ee276b "powerpc/boot: Use the pre-boot decompression API" breaks boot
From: "Oliver O'Halloran" <oohall@gmail.com>
Date: 2016-10-12 04:26:29
On Tue, Oct 11, 2016 at 7:06 AM, Heiner Kallweit [off-list ref] wrote:
quoted
IMHO in case of using cuboot no CONFIG_KERNEL_<COMPR TYPE> config option should be set and Makefile + code in arch/powerpc/boot should be able to deal with this situation: - don't copy and build the decompression stuff - use an alternative version of prep_kernel() in main.c which doesn't attempt to decompress the kernel image This should be a cleaner solution than probing the kernel image whether it's compressed or not.This would be the patch implementing the idea. Advantage is that all the unnecessary decompression code isn't built. Works fine for me.
I don't think this approach is viable. The wrapper code is shared among the various output image formats some of which *will* contain a compressed kernel image so we can't simply remove the decompressor from the wrapper. A random example I found in the makefile was CONFIG_BAMBOO:
image-$(CONFIG_BAMBOO) += treeImage.bamboo cuImage.bamboo
When building for this platform Kbuild will produce treeboot and a cuboot image. Unlike uboot, Treeboot doesn't do any decompression so the wrapper needs to decompress the kernel itself. The probing solution more or less matches the old behaviour (which we know works) so I think we should just stick with that. - Oliver