ARM: verify size of zImage
authorRussell King <rmk+kernel@armlinux.org.uk>
Mon, 23 Oct 2017 11:39:32 +0000 (12:39 +0100)
committerRussell King <rmk+kernel@armlinux.org.uk>
Sun, 17 Dec 2017 22:14:05 +0000 (22:14 +0000)
commit55e7cff44c7c322310aded74ed92c54b22ccccd4
treeed25c04f6de4941be1f315319986dfe76382f177
parent4fbd8d194f06c8a3fd2af1ce560ddb31f7ec8323
ARM: verify size of zImage

The linker can sometimes add additional sections to the zImage ELF file
which results in the zImage binary being larger than expected.  This
causes appended DT blobs to fail.

Verify that the zImage binary is the expected size, and fail the build
if this is not the case.

We need to include the .data.rel.ro section in the image as the RiscPC
build includes font data that contains a small amount of data in this
section.

Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Tested-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
arch/arm/boot/compressed/vmlinux.lds.S