[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL v2 14/17] linux-user/uname: Return correct uname stri
From: |
riku . voipio |
Subject: |
[Qemu-devel] [PULL v2 14/17] linux-user/uname: Return correct uname string for x86_64 |
Date: |
Tue, 17 Jun 2014 17:56:57 +0300 |
From: Peter Maydell <address@hidden>
We were returning the incorrect uname string (with a hyphen, not
an underscore) for x86_64. Fix this by removing the x86_64 special
case, since the default "just use UNAME_MACHINE" behaviour suffices.
This leaves cpu_to_uname_machine() special cases for only those
architectures which need to vary the string based on runtime CPU
features.
Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>
---
linux-user/uname.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/linux-user/uname.c b/linux-user/uname.c
index f5d4c66..1e6560d 100644
--- a/linux-user/uname.c
+++ b/linux-user/uname.c
@@ -52,9 +52,7 @@ const char *cpu_to_uname_machine(void *cpu_env)
/* earliest emulated CPU is ARMv5TE; qemu can emulate the 1026, but not its
* Jazelle support */
return "armv5te" utsname_suffix;
-#elif defined(TARGET_X86_64)
- return "x86-64";
-#elif defined(TARGET_I386)
+#elif defined(TARGET_I386) && !defined(TARGET_X86_64)
/* see arch/x86/kernel/cpu/bugs.c: check_bugs(), 386, 486, 586, 686 */
CPUState *cpu = ENV_GET_CPU((CPUX86State *)cpu_env);
int family = object_property_get_int(OBJECT(cpu), "family", NULL);
--
2.0.0.rc2
- [Qemu-devel] [PULL v2 00/17] linux-user updates, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 10/17] signal/ppc/{save, restore}_user_regs remove __put/get error checks, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 02/17] signal/x86/setup_frame: __put_user cleanup, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 12/17] signal/ppc/do_setcontext remove __get_user return check, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 04/17] signal/all: remove return value from setup_sigcontext, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 17/17] User mode support for Linux ELF files with no section header, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 08/17] signal/all/do_sigreturn - remove __get_user checks, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 16/17] linux-user: Return correct errno for unsupported netlink socket, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 03/17] signal/all: remove return value from copy_siginfo_to_user, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 01/17] signal/all: remove __get/__put_user return value reading, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 14/17] linux-user/uname: Return correct uname string for x86_64,
riku . voipio <=
- [Qemu-devel] [PULL v2 11/17] signal/sparc64_set_context: remove __get_user checks, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 09/17] signal/all/setup_frame remove __put_user checks, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 13/17] linux-user: fix gcc-4.9 compiler error on __{get, put]}_user, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 15/17] linux-user: Don't overrun guest buffer in sched_getaffinity, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 07/17] signal/all/do_sigaltstack remove __get_user value check, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 06/17] signal/sparc/restore_fpu_state: remove, riku . voipio, 2014/06/17
- [Qemu-devel] [PULL v2 05/17] signal/all: remove return value from restore_sigcontext, riku . voipio, 2014/06/17
- Re: [Qemu-devel] [PULL v2 00/17] linux-user updates, Peter Maydell, 2014/06/17