CONFIG_ARM64 was added as an alternative to CONFIG_CPU_V8 as encountering the latter in generic code is confusing for users not familiar with ARM. EFI payload support was one such generic place, so let's replace the CONFIG_CPU_v8 instance there with the new symbol. The if clause is moved to keep the order elsewhere in the file, where x86 checks are done before those for ARM. Both can't be active at the same time, so no functional change expected. Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx> --- efi/payload/image.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/efi/payload/image.c b/efi/payload/image.c index 6a41338f2a2f..70b57360c99d 100644 --- a/efi/payload/image.c +++ b/efi/payload/image.c @@ -163,7 +163,7 @@ static bool is_linux_image(enum filetype filetype, const void *base) hdr->boot_flag == 0xAA55 && hdr->header == 0x53726448) return true; - if (IS_ENABLED(CONFIG_CPU_V8) && + if (IS_ENABLED(CONFIG_ARM64) && filetype == filetype_arm64_efi_linux_image) return true; @@ -367,12 +367,12 @@ static int efi_register_image_handler(void) register_image_handler(&efi_handle_tr); binfmt_register(&binfmt_efi_hook); - if (IS_ENABLED(CONFIG_CPU_V8)) - binfmt_register(&binfmt_arm64_efi_hook); - if (IS_ENABLED(CONFIG_X86)) register_image_handler(&non_efi_handle_linux_x86); + if (IS_ENABLED(CONFIG_ARM64)) + binfmt_register(&binfmt_arm64_efi_hook); + return 0; } late_efi_initcall(efi_register_image_handler); -- 2.39.5