efi: Export boot-services code and data as debugfs-blobs
authorHans de Goede <hdegoede@redhat.com>
Wed, 15 Jan 2020 16:35:45 +0000 (17:35 +0100)
committerArd Biesheuvel <ardb@kernel.org>
Tue, 3 Mar 2020 09:27:30 +0000 (10:27 +0100)
commit0e72a6a3cfc3a32273f5e99bfaa4407f4917d343
tree5d44b2405c3c655701b6a1a72d3100dc4b85d4dd
parentbb6d3fb354c5ee8d6bde2d576eb7220ea09862b9
efi: Export boot-services code and data as debugfs-blobs

Sometimes it is useful to be able to dump the efi boot-services code and
data. This commit adds these as debugfs-blobs to /sys/kernel/debug/efi,
but only if efi=debug is passed on the kernel-commandline as this requires
not freeing those memory-regions, which costs 20+ MB of RAM.

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20200115163554.101315-2-hdegoede@redhat.com
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
arch/x86/platform/efi/efi.c
arch/x86/platform/efi/quirks.c
drivers/firmware/efi/efi.c
include/linux/efi.h