qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH 4/4] multiboot: Make elf64 loading functionality com


From: Anatol Pomozov
Subject: [Qemu-devel] [PATCH 4/4] multiboot: Make elf64 loading functionality compatible with GRUB
Date: Mon, 29 Jan 2018 12:43:44 -0800

GRUB is a reference multiboot implementation and supports loading elf64
binaries. Make QEMU to work similar was as GRUB.
---
 hw/i386/multiboot.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/hw/i386/multiboot.c b/hw/i386/multiboot.c
index 79b89e4fee..676ac7c48d 100644
--- a/hw/i386/multiboot.c
+++ b/hw/i386/multiboot.c
@@ -168,11 +168,6 @@ int load_multiboot(FWCfgState *fw_cfg,
         int kernel_size;
         fclose(f);
 
-        if (((struct elf64_hdr*)header)->e_machine == EM_X86_64) {
-            fprintf(stderr, "Cannot load x86-64 image, give a 32bit one.\n");
-            exit(1);
-        }
-
         kernel_size = load_elf_ram(kernel_filename, NULL, NULL, &elf_entry,
                                &elf_low, &elf_high, 0, I386_ELF_MACHINE,
                                0, 0, NULL, true, &sections);
-- 
2.16.0.rc1.238.g530d649a79-goog




reply via email to

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