efi/loongarch: libstub: Split off kernel image relocation for builtin stub
authorArd Biesheuvel <ardb@kernel.org>
Thu, 13 Oct 2022 10:39:37 +0000 (12:39 +0200)
committerArd Biesheuvel <ardb@kernel.org>
Wed, 9 Nov 2022 11:42:03 +0000 (12:42 +0100)
commitd729b554e17904e16498ab5c36122d70406f70ae
tree4e92feaaf8f113303819738041af89e0be6defef
parent0efb61c89fa021dfcdb92f22bbc9a7cb3f0fe3fe
efi/loongarch: libstub: Split off kernel image relocation for builtin stub

The LoongArch build of the EFI stub is part of the core kernel image, and
therefore accesses section markers directly when it needs to figure out
the size of the various section.

The zboot decompressor does not have access to those symbols, but
doesn't really need that either. So let's move handle_kernel_image()
into a separate file (or rather, move everything else into a separate
file) so that the zboot build does not pull in unused code that links to
symbols that it does not define.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
drivers/firmware/efi/libstub/Makefile
drivers/firmware/efi/libstub/loongarch-stub.c
drivers/firmware/efi/libstub/loongarch.c [new file with mode: 0644]