linux/arch/x86/platform/efi
Dov Murik 1227418989 efi: Save location of EFI confidential computing area
Confidential computing (coco) hardware such as AMD SEV (Secure Encrypted
Virtualization) allows a guest owner to inject secrets into the VMs
memory without the host/hypervisor being able to read them.

Firmware support for secret injection is available in OVMF, which
reserves a memory area for secret injection and includes a pointer to it
the in EFI config table entry LINUX_EFI_COCO_SECRET_TABLE_GUID.

If EFI exposes such a table entry, uefi_init() will keep a pointer to
the EFI config table entry in efi.coco_secret, so it can be used later
by the kernel (specifically drivers/virt/coco/efi_secret).  It will also
appear in the kernel log as "CocoSecret=ADDRESS"; for example:

    [    0.000000] efi: EFI v2.70 by EDK II
    [    0.000000] efi: CocoSecret=0x7f22e680 SMBIOS=0x7f541000 ACPI=0x7f77e000 ACPI 2.0=0x7f77e014 MEMATTR=0x7ea0c018

The new functionality can be enabled with CONFIG_EFI_COCO_SECRET=y.

Signed-off-by: Dov Murik <dovmurik@linux.ibm.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Link: https://lore.kernel.org/r/20220412212127.154182-2-dovmurik@linux.ibm.com
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
2022-04-13 19:11:18 +02:00
..
efi_32.c efi/x86: Move 32-bit code into efi_32.c 2020-08-20 11:18:36 +02:00
efi_64.c x86/sev: Replace occurrences of sev_active() with cc_platform_has() 2021-10-04 11:46:58 +02:00
efi_stub_32.S x86: Prepare asm files for straight-line-speculation 2021-12-08 12:25:37 +01:00
efi_stub_64.S x86: Prepare asm files for straight-line-speculation 2021-12-08 12:25:37 +01:00
efi_thunk_64.S objtool,efi: Update __efi64_thunk annotation 2022-03-15 10:32:32 +01:00
efi.c efi: Save location of EFI confidential computing area 2022-04-13 19:11:18 +02:00
Makefile objtool,efi: Update __efi64_thunk annotation 2022-03-15 10:32:32 +01:00
quirks.c x86/sme: Explicitly map new EFI memmap table as encrypted 2021-12-05 16:44:52 +01:00