diff options
author | Ard Biesheuvel <ard.biesheuvel@linaro.org> | 2016-03-30 17:43:07 +0200 |
---|---|---|
committer | Will Deacon <will.deacon@arm.com> | 2016-04-14 18:11:30 +0100 |
commit | 546c8c44f092b2f23291fe499c221efc8cabbb67 (patch) | |
tree | e778a9304a332f72f505490ed19d9178fd3b3541 /arch/arm64/kernel/image.h | |
parent | 2c09ec06bc39fc85a2b3856524348c301def27af (diff) | |
download | linux-stable-546c8c44f092b2f23291fe499c221efc8cabbb67.tar.gz linux-stable-546c8c44f092b2f23291fe499c221efc8cabbb67.tar.bz2 linux-stable-546c8c44f092b2f23291fe499c221efc8cabbb67.zip |
arm64: move early boot code to the .init segment
Apart from the arm64/linux and EFI header data structures, there is nothing
in the .head.text section that must reside at the beginning of the Image.
So let's move it to the .init section where it belongs.
Note that this involves some minor tweaking of the EFI header, primarily
because the address of 'stext' no longer coincides with the start of the
.text section. It also requires a couple of relocated symbol references
to be slightly rewritten or their definition moved to the linker script.
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'arch/arm64/kernel/image.h')
-rw-r--r-- | arch/arm64/kernel/image.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm64/kernel/image.h b/arch/arm64/kernel/image.h index 5e360ce88f10..4fd72da646a3 100644 --- a/arch/arm64/kernel/image.h +++ b/arch/arm64/kernel/image.h @@ -71,8 +71,12 @@ DEFINE_IMAGE_LE64(_kernel_offset_le, TEXT_OFFSET); \ DEFINE_IMAGE_LE64(_kernel_flags_le, __HEAD_FLAGS); +kernel_img_size = _end - (_text - TEXT_OFFSET); + #ifdef CONFIG_EFI +__efistub_stext_offset = stext - _text; + /* * Prevent the symbol aliases below from being emitted into the kallsyms * table, by forcing them to be absolute symbols (which are conveniently |