Documentation/x86, efi/x86: Clarify EFI handover protocol and its requirements
authorArd Biesheuvel <ardb@kernel.org>
Thu, 9 Apr 2020 13:04:31 +0000 (15:04 +0200)
committerIngo Molnar <mingo@kernel.org>
Tue, 14 Apr 2020 06:32:15 +0000 (08:32 +0200)
commit8b84769a7a1505b279b337dae83d16390e83f5c1
tree1b0370bb59a3510436af239d920c77104daec8b2
parenta94691680bace7e1404e4f235badb74e30467e86
Documentation/x86, efi/x86: Clarify EFI handover protocol and its requirements

The EFI handover protocol was introduced on x86 to permit the boot
loader to pass a populated boot_params structure as an additional
function argument to the entry point. This allows the bootloader to
pass the base and size of a initrd image, which is more flexible
than relying on the EFI stub's file I/O routines, which can only
access the file system from which the kernel image itself was loaded
from firmware.

This approach requires a fair amount of internal knowledge regarding
the layout of the boot_params structure on the part of the boot loader,
as well as knowledge regarding the allowed placement of the initrd in
memory, and so it has been deprecated in favour of a new initrd loading
method that is based on existing UEFI protocols and best practices.

So update the x86 boot protocol documentation to clarify that the EFI
handover protocol has been deprecated, and while at it, add a note that
invoking the EFI handover protocol still requires the PE/COFF image to
be loaded properly (as opposed to simply being copied into memory).
Also, drop the code32_start header field from the list of values that
need to be provided, as this is no longer required.

Reviewed-by: Borislav Petkov <bp@suse.de>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20200409130434.6736-7-ardb@kernel.org
Documentation/x86/boot.rst