efi: Merge EFI system table revision and vendor checks
authorArd Biesheuvel <ardb@kernel.org>
Mon, 20 Jan 2020 09:49:11 +0000 (10:49 +0100)
committerArd Biesheuvel <ardb@kernel.org>
Sun, 23 Feb 2020 20:59:42 +0000 (21:59 +0100)
commit14fb4209094355928d5a742e35afabdf7b404c17
tree79792232114882e957fb6d6ae3a1eba906099a3d
parentb7846e6be235c4a19337a32168b27ed836a1504e
efi: Merge EFI system table revision and vendor checks

We have three different versions of the code that checks the EFI system
table revision and copies the firmware vendor string, and they are
mostly equivalent, with the exception of the use of early_memremap_ro
vs. __va() and the lowest major revision to warn about. Let's move this
into common code and factor out the commonalities.

Tested-by: Tony Luck <tony.luck@intel.com> # arch/ia64
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
arch/ia64/kernel/efi.c
arch/x86/platform/efi/efi.c
drivers/firmware/efi/arm-init.c
drivers/firmware/efi/efi.c
include/linux/efi.h