diff options
author | Ard Biesheuvel <ardb@kernel.org> | 2023-08-07 19:27:17 +0300 |
---|---|---|
committer | Borislav Petkov (AMD) <bp@alien8.de> | 2023-08-07 21:59:13 +0300 |
commit | 83381519352d6b5b3e429bf72aaab907480cb6b6 (patch) | |
tree | 99ac13da6a50856123956ce17bb757b256ee6631 /arch/x86/include/asm/boot.h | |
parent | 24388292e2d7fae79a0d4183cc91716b851299cf (diff) | |
download | linux-83381519352d6b5b3e429bf72aaab907480cb6b6.tar.xz |
x86/decompressor: Factor out kernel decompression and relocation
Factor out the decompressor sequence that invokes the decompressor,
parses the ELF and applies the relocations so that it can be called
directly from the EFI stub.
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/r/20230807162720.545787-21-ardb@kernel.org
Diffstat (limited to 'arch/x86/include/asm/boot.h')
-rw-r--r-- | arch/x86/include/asm/boot.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/x86/include/asm/boot.h b/arch/x86/include/asm/boot.h index 9191280d9ea3..4ae14339cb8c 100644 --- a/arch/x86/include/asm/boot.h +++ b/arch/x86/include/asm/boot.h @@ -62,4 +62,12 @@ # define BOOT_STACK_SIZE 0x1000 #endif +#ifndef __ASSEMBLY__ +extern unsigned int output_len; +extern const unsigned long kernel_total_size; + +unsigned long decompress_kernel(unsigned char *outbuf, unsigned long virt_addr, + void (*error)(char *x)); +#endif + #endif /* _ASM_X86_BOOT_H */ |