diff options
Diffstat (limited to 'target/arm')
-rw-r--r-- | target/arm/cpu.c | 2 | ||||
-rw-r--r-- | target/arm/cpu.h | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/target/arm/cpu.c b/target/arm/cpu.c index 412e94c7ad..20a3445bda 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 5a1f957c51..6e50ae2b55 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 |