aboutsummaryrefslogtreecommitdiff
path: root/target
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2017-09-20 17:35:36 +0100
committerPeter Maydell <peter.maydell@linaro.org>2017-09-20 17:35:36 +0100
commitd3f5433c7b4aa2d59c6de4175743f4126e181aea (patch)
tree4f800d0b63205194e3049a23b378783e21b96d8a /target
parentc51700273ad9802a21c19f8d2b4bcb67c38e74ac (diff)
parente3d038b89f1bf3f09da4d59aa16b16e8305e1a05 (diff)
downloadqemu-d3f5433c7b4aa2d59c6de4175743f4126e181aea.zip
qemu-d3f5433c7b4aa2d59c6de4175743f4126e181aea.tar.gz
qemu-d3f5433c7b4aa2d59c6de4175743f4126e181aea.tar.bz2
Merge remote-tracking branch 'remotes/ehabkost/tags/machine-next-pull-request' into staging
Machine/CPU/NUMA queue, 2017-09-19 # gpg: Signature made Tue 19 Sep 2017 21:17:01 BST # gpg: using RSA key 0x2807936F984DC5A6 # gpg: Good signature from "Eduardo Habkost <ehabkost@redhat.com>" # Primary key fingerprint: 5A32 2FD5 ABC4 D3DB ACCF D1AA 2807 936F 984D C5A6 * remotes/ehabkost/tags/machine-next-pull-request: MAINTAINERS: Update git URLs for my trees hw/acpi-build: Fix SRAT memory building in case of node 0 without RAM NUMA: Replace MAX_NODES with nb_numa_nodes in for loop numa: cpu: calculate/set default node-ids after all -numa CLI options are parsed arm: drop intermediate cpu_model -> cpu type parsing and use cpu type directly pc: use generic cpu_model parsing vl.c: convert cpu_model to cpu type and set of global properties before machine_init() cpu: make cpu_generic_init() abort QEMU on error qom: cpus: split cpu_generic_init() on feature parsing and cpu creation parts hostmem-file: Add "discard-data" option osdep: Define QEMU_MADV_REMOVE vl: Clean up user-creatable objects when exiting Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target')
-rw-r--r--target/arm/cpu.c2
-rw-r--r--target/arm/cpu.h3
-rw-r--r--target/i386/cpu.c3
-rw-r--r--target/i386/cpu.h9
4 files changed, 13 insertions, 4 deletions
diff --git a/target/arm/cpu.c b/target/arm/cpu.c
index 412e94c..20a3445 100644
--- a/target/arm/cpu.c
+++ b/target/arm/cpu.c
@@ -911,7 +911,7 @@ static ObjectClass *arm_cpu_class_by_name(const char *cpu_model)
}
cpuname = g_strsplit(cpu_model, ",", 1);
- typename = g_strdup_printf("%s-" TYPE_ARM_CPU, cpuname[0]);
+ typename = g_strdup_printf(ARM_CPU_TYPE_NAME("%s"), cpuname[0]);
oc = object_class_by_name(typename);
g_strfreev(cpuname);
g_free(typename);
diff --git a/target/arm/cpu.h b/target/arm/cpu.h
index 5a1f957..6e50ae2 100644
--- a/target/arm/cpu.h
+++ b/target/arm/cpu.h
@@ -2091,6 +2091,9 @@ static inline bool arm_excp_unmasked(CPUState *cs, unsigned int excp_idx,
#define cpu_init(cpu_model) cpu_generic_init(TYPE_ARM_CPU, cpu_model)
+#define ARM_CPU_TYPE_SUFFIX "-" TYPE_ARM_CPU
+#define ARM_CPU_TYPE_NAME(name) (name ARM_CPU_TYPE_SUFFIX)
+
#define cpu_signal_handler cpu_arm_signal_handler
#define cpu_list arm_cpu_list
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 4b0fa06..0aa28fc 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -705,9 +705,6 @@ void host_vendor_fms(char *vendor, int *family, int *model, int *stepping)
/* CPU class name definitions: */
-#define X86_CPU_TYPE_SUFFIX "-" TYPE_X86_CPU
-#define X86_CPU_TYPE_NAME(name) (name X86_CPU_TYPE_SUFFIX)
-
/* Return type name for a given CPU model name
* Caller is responsible for freeing the returned string.
*/
diff --git a/target/i386/cpu.h b/target/i386/cpu.h
index 0f80de1..b086b15 100644
--- a/target/i386/cpu.h
+++ b/target/i386/cpu.h
@@ -1510,6 +1510,15 @@ uint64_t cpu_get_tsc(CPUX86State *env);
#define cpu_init(cpu_model) cpu_generic_init(TYPE_X86_CPU, cpu_model)
+#define X86_CPU_TYPE_SUFFIX "-" TYPE_X86_CPU
+#define X86_CPU_TYPE_NAME(name) (name X86_CPU_TYPE_SUFFIX)
+
+#ifdef TARGET_X86_64
+#define TARGET_DEFAULT_CPU_TYPE X86_CPU_TYPE_NAME("qemu64")
+#else
+#define TARGET_DEFAULT_CPU_TYPE X86_CPU_TYPE_NAME("qemu32")
+#endif
+
#define cpu_signal_handler cpu_x86_signal_handler
#define cpu_list x86_cpu_list