提交 74bcc249 编写于 作者: L Leif Lindholm 提交者: Matt Fleming

arm64: efi: only attempt efi map setup if booting via EFI

Booting a kernel with CONFIG_EFI enabled on a non-EFI system caused
an oops with the current UEFI support code.
Add the required test to prevent this.
Signed-off-by: NLeif Lindholm <leif.lindholm@linaro.org>
Acked-by: NCatalin Marinas <catalin.marinas@arm.com>
Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
上级 345c736e
......@@ -333,6 +333,9 @@ void __init efi_init(void)
void __init efi_idmap_init(void)
{
if (!efi_enabled(EFI_BOOT))
return;
/* boot time idmap_pg_dir is incomplete, so fill in missing parts */
efi_setup_idmap();
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册