diff options
author | Juergen Gross <[email protected]> | 2017-05-26 12:36:47 +0100 |
---|---|---|
committer | Ingo Molnar <[email protected]> | 2017-05-28 11:06:16 +0200 |
commit | 1ea34adb87c969b89dfd83f1905a79161e9ada26 (patch) | |
tree | 354be06ec560f8db15bbc0b7fc3cc6ac612a41b3 | |
parent | 249f1efd8e3d58f86469fc305b0eda39db18d7ce (diff) |
efi: Don't issue error message when booted under Xen
When booted as Xen dom0 there won't be an EFI memmap allocated. Avoid
issuing an error message in this case:
[ 0.144079] efi: Failed to allocate new EFI memmap
Signed-off-by: Juergen Gross <[email protected]>
Signed-off-by: Matt Fleming <[email protected]>
Cc: <[email protected]> # v4.9+
Cc: Ard Biesheuvel <[email protected]>
Cc: Linus Torvalds <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: [email protected]
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
-rw-r--r-- | arch/x86/platform/efi/quirks.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/x86/platform/efi/quirks.c b/arch/x86/platform/efi/quirks.c index 26615991d69c..e0cf95a83f3f 100644 --- a/arch/x86/platform/efi/quirks.c +++ b/arch/x86/platform/efi/quirks.c @@ -360,6 +360,9 @@ void __init efi_free_boot_services(void) free_bootmem_late(start, size); } + if (!num_entries) + return; + new_size = efi.memmap.desc_size * num_entries; new_phys = efi_memmap_alloc(num_entries); if (!new_phys) { |