Commit 789957ef authored by Ard Biesheuvel's avatar Ard Biesheuvel Committed by Ingo Molnar
Browse files

efi/arm*: Take the Memory Attributes table into account

Call into the generic memory attributes table support code at the
appropriate times during the init sequence so that the UEFI Runtime
Services region are mapped according to the strict permissions it

Signed-off-by: default avatarArd Biesheuvel <>
Signed-off-by: default avatarMatt Fleming <>
Cc: Borislav Petkov <>
Cc: Catalin Marinas <>
Cc: Leif Lindholm <>
Cc: Mark Rutland <>
Cc: Peter Jones <>
Cc: Peter Zijlstra <>
Cc: Sai Praneeth Prakhya <>
Cc: Thomas Gleixner <>
Cc: Will Deacon <>

Signed-off-by: default avatarIngo Molnar <>
parent 10f0d2f5
......@@ -14,6 +14,8 @@ extern void efi_init(void);
int efi_create_mapping(struct mm_struct *mm, efi_memory_desc_t *md);
#define efi_set_mapping_permissions efi_create_mapping
#define efi_call_virt(f, ...) \
({ \
efi_##f##_t *__f; \
......@@ -206,6 +206,7 @@ void __init efi_init(void)
early_memunmap(, params.mmap_size);
......@@ -77,9 +77,15 @@ static bool __init efi_virtmap_init(void)
systab_found = true;
if (!systab_found)
if (!systab_found) {
pr_err("No virtual mapping found for the UEFI System Table\n");
return systab_found;
return false;
if (efi_memattr_apply_permissions(&efi_mm, efi_set_mapping_permissions))
return false;
return true;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment