From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36428) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZePAe-0002sY-W7 for qemu-devel@nongnu.org; Tue, 22 Sep 2015 11:07:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZePAb-0001KX-41 for qemu-devel@nongnu.org; Tue, 22 Sep 2015 11:07:52 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51682) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZePAa-0001KT-Vz for qemu-devel@nongnu.org; Tue, 22 Sep 2015 11:07:49 -0400 From: Paolo Bonzini Date: Tue, 22 Sep 2015 17:06:02 +0200 Message-Id: <1442934371-12567-40-git-send-email-pbonzini@redhat.com> In-Reply-To: <1442934371-12567-1-git-send-email-pbonzini@redhat.com> References: <1442934371-12567-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 39/48] or32: Remove ELF_MACHINE from cpu.h List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Crosthwaite , Jia Liu , Peter Crosthwaite From: Peter Crosthwaite The only generic code relying on this is linux-user, but linux users' default behaviour of defaulting ELF_MACHINE to ELF_ARCH will handle this. The bootloader can just pass EM_OPENRISC directly, as that is architecture specific code. This removes another architecture specific definition from the global namespace. Cc: Jia Liu Reviewed-by: Richard Henderson Acked-By: Riku Voipio Signed-off-by: Peter Crosthwaite Signed-off-by: Paolo Bonzini --- hw/openrisc/openrisc_sim.c | 2 +- target-openrisc/cpu.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/openrisc/openrisc_sim.c b/hw/openrisc/openrisc_sim.c index 5f26785..be6c9b5 100644 --- a/hw/openrisc/openrisc_sim.c +++ b/hw/openrisc/openrisc_sim.c @@ -68,7 +68,7 @@ static void cpu_openrisc_load_kernel(ram_addr_t ram_size, if (kernel_filename && !qtest_enabled()) { kernel_size = load_elf(kernel_filename, NULL, NULL, - &elf_entry, NULL, NULL, 1, ELF_MACHINE, 1); + &elf_entry, NULL, NULL, 1, EM_OPENRISC, 1); entry = elf_entry; if (kernel_size < 0) { kernel_size = load_uimage(kernel_filename, diff --git a/target-openrisc/cpu.h b/target-openrisc/cpu.h index 560210d9..1ff1c9e 100644 --- a/target-openrisc/cpu.h +++ b/target-openrisc/cpu.h @@ -21,7 +21,6 @@ #define CPU_OPENRISC_H #define TARGET_LONG_BITS 32 -#define ELF_MACHINE EM_OPENRISC #define CPUArchState struct CPUOpenRISCState -- 2.5.0