[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 1/1] grub-mkimage: Creating aarch64 images from x86 host is broke

From: Darren Kenny
Subject: [PATCH 1/1] grub-mkimage: Creating aarch64 images from x86 host is broken
Date: Wed, 27 Apr 2022 10:46:48 +0000

A recent fix that made appears to have broken the ability to create an
aarch64 boot image on a x86-based host.

This was due to an overzealous testing of the architecture when building
grub-mkimage and removing the code that build an Arm image when not
built on Arm.

Fixes: 8541f319 ("grub-mkimage: Only check aarch64 relocations when built for 

Signed-off-by: Darren Kenny <>
Tested-by: Selva Ganesan <>
 util/grub-mkimagexx.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/util/grub-mkimagexx.c b/util/grub-mkimagexx.c
index 1e29e255e8d2..a1927e786928 100644
--- a/util/grub-mkimagexx.c
+++ b/util/grub-mkimagexx.c
@@ -1631,7 +1631,7 @@ translate_relocation_pe (struct translate_context *ctx,
     case EM_AARCH64:
-#if defined(MKIMAGE_ELF64) && defined(__arm__)
+#if defined(MKIMAGE_ELF64)
       switch (ELF_R_TYPE (info))
        case R_AARCH64_ABS64:
@@ -1667,8 +1667,7 @@ translate_relocation_pe (struct translate_context *ctx,
                           (unsigned int) ELF_R_TYPE (info));
-#endif /* defined(MKIMAGE_ELF64) && define(__arm__) */
-      break;
+#endif /* defined(MKIMAGE_ELF64) */
 #if defined(MKIMAGE_ELF32)
     case EM_ARM:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]