summaryrefslogtreecommitdiff
path: root/target/ppc/cpu-models.c
diff options
context:
space:
mode:
authorIgor Mammedov <imammedo@redhat.com>2017-08-30 15:24:29 +0200
committerDavid Gibson <david@gibson.dropbear.id.au>2017-09-08 09:30:55 +1000
commitc9137065814609111ec0ed29246388f4ad086732 (patch)
treee97ebfb1e7aefe453fe46d935f4a06f77a08ec40 /target/ppc/cpu-models.c
parentbf1457bdbb736a54eb2eb70bc531e11eb468de7e (diff)
downloadqemu-c9137065814609111ec0ed29246388f4ad086732.tar.gz
ppc: use macros to make cpu type name from string literal
Replace "-" TYPE_POWERPC_CPU when composing cpu type name from cpu model string literal and the same pattern in format strings with POWERPC_CPU_TYPE_SUFFIX and POWERPC_CPU_TYPE_NAME(model) macroses like we do in x86. Later POWERPC_CPU_TYPE_NAME() will be used to define default cpu type per machine type and as bonus it will be consistent and easy grep-able pattern across all other targets that I'm plannig to treat the same way. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'target/ppc/cpu-models.c')
-rw-r--r--target/ppc/cpu-models.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/ppc/cpu-models.c b/target/ppc/cpu-models.c
index e0d9faf848..782977425b 100644
--- a/target/ppc/cpu-models.c
+++ b/target/ppc/cpu-models.c
@@ -51,7 +51,7 @@
\
static const TypeInfo \
glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_type_info) = { \
- .name = _name "-" TYPE_POWERPC_CPU, \
+ .name = POWERPC_CPU_TYPE_NAME(_name), \
.parent = stringify(_type) "-family-" TYPE_POWERPC_CPU, \
.class_init = \
glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init), \