it will be used for for 2 purposes, 1st is to
provide to cpu name resolving class for machine 'none'
  cpu_parse_cpu_model(machine_class->default_cpu_type, cpu_model)
and later to drop a bunch of ifdefs *-user/main.c that
set default cpu_model.

Use default values from linux-user for TARGET_DEFAULT_CPU_TYPE.

Signed-off-by: Igor Mammedov <imamm...@redhat.com>
---
CC: Mark Cave-Ayland <mark.cave-ayl...@ilande.co.uk>
CC: Artyom Tarasenko <atar4q...@gmail.com>
---
 target/sparc/cpu.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/target/sparc/cpu.h b/target/sparc/cpu.h
index 9fde547..02c55ad 100644
--- a/target/sparc/cpu.h
+++ b/target/sparc/cpu.h
@@ -661,6 +661,12 @@ int cpu_sparc_signal_handler(int host_signum, void *pinfo, 
void *puc);
 #define SPARC_CPU_TYPE_SUFFIX "-" TYPE_SPARC_CPU
 #define SPARC_CPU_TYPE_NAME(model) model SPARC_CPU_TYPE_SUFFIX
 
+#ifdef TARGET_SPARC64
+#define TARGET_DEFAULT_CPU_TYPE SPARC_CPU_TYPE_NAME("TI-UltraSparc-II")
+#else
+#define TARGET_DEFAULT_CPU_TYPE SPARC_CPU_TYPE_NAME("Fujitsu-MB86904")
+#endif
+
 #define cpu_signal_handler cpu_sparc_signal_handler
 #define cpu_list sparc_cpu_list
 
-- 
2.7.4


Reply via email to