summaryrefslogtreecommitdiff
path: root/kexec/kexec-elf.c
diff options
context:
space:
mode:
authorDaniel Mack <zonque@gmail.com>2013-11-13 16:16:35 +0100
committerSimon Horman <horms@verge.net.au>2013-11-14 13:14:59 +0900
commit84a5bf32e842d519e90692bda178388d788ddc3e (patch)
tree5a94e57ca03d58964dd45cdd751ce38b98e66310 /kexec/kexec-elf.c
parent1cbddc80ddfe34cdcdac11c0562e4d8395c48b16 (diff)
arm: add command line option for the total image size
Currently, kexec on arm assumes that it's safe to place binary images such as atags, dtb or initrd at an estimated offset after the load address. That estimated offset is set to 4 times the size of the compressed image, hence assuming a minimum compression ratio of 1:4. While that assumption matches what the in-kernel compressors are able to achive, it doesn't take into account the .bss section the kernel image carries, and which can grow to arbitrary sizes while not accounting to the compressed image size. After decompression, and before the execution of the compressed kernel, the .bss area is initialized to zeros, trampeling over the binary images in case they happen to live in that piece of memory. Unfortunately, determining the full image size is not easiliy possible at runtime, as it would include doing all possible ways of decompression and then walk the ELF sections by hand. For now, allow users to override the static offset with a new, arm specific command line argument. Users are supposed to set this, and determine a sane value by using 'arm-linux-size vmlinux'. Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Simon Horman <horms@verge.net.au>
Diffstat (limited to 'kexec/kexec-elf.c')
0 files changed, 0 insertions, 0 deletions