projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
abc93f8
)
arch/x86: Do not access EFI memory map if it is not available
author
Daniel Kiper
<daniel.kiper@oracle.com>
Mon, 30 Jun 2014 17:52:57 +0000
(19:52 +0200)
committer
Matt Fleming
<matt.fleming@intel.com>
Fri, 18 Jul 2014 20:23:54 +0000
(21:23 +0100)
Do not access EFI memory map if it is not available. At least
Xen dom0 EFI implementation does not have an access to it.
Signed-off-by: Daniel Kiper <daniel.kiper@oracle.com>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
arch/x86/platform/efi/efi.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/x86/platform/efi/efi.c
b/arch/x86/platform/efi/efi.c
index b4059720962389fbf584dbd491332c37e7b58751..7d627a02ed82d8d6cdb0328d1b78bf3379721f70 100644
(file)
--- a/
arch/x86/platform/efi/efi.c
+++ b/
arch/x86/platform/efi/efi.c
@@
-946,6
+946,9
@@
u64 efi_mem_attributes(unsigned long phys_addr)
efi_memory_desc_t *md;
void *p;
+ if (!efi_enabled(EFI_MEMMAP))
+ return 0;
+
for (p = memmap.map; p < memmap.map_end; p += memmap.desc_size) {
md = p;
if ((md->phys_addr <= phys_addr) &&