diff mbox series

[02/24] alpha: cpu: add TARGET_DEFAULT_CPU_TYPE macro

Message ID 1516203816-19374-3-git-send-email-imammedo@redhat.com
State New
Headers show
Series generalize parsing of cpu_model (part 4) | expand

Commit Message

Igor Mammedov Jan. 17, 2018, 3:43 p.m. UTC
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.

With the later in mind set it to 'ev67', which is
what alpha_cpu_class_by_name() returns if user provided
a garbage (including default "any" cpu_model that *-user
targets set in catch all) in case of Alpha.

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
CC: Richard Henderson <rth@twiddle.net>
---
 target/alpha/cpu.h | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/target/alpha/cpu.h b/target/alpha/cpu.h
index 0a9ad35..c8dd560 100644
--- a/target/alpha/cpu.h
+++ b/target/alpha/cpu.h
@@ -472,6 +472,7 @@  void alpha_translate_init(void);
 
 #define ALPHA_CPU_TYPE_SUFFIX "-" TYPE_ALPHA_CPU
 #define ALPHA_CPU_TYPE_NAME(model) model ALPHA_CPU_TYPE_SUFFIX
+#define TARGET_DEFAULT_CPU_TYPE ALPHA_CPU_TYPE_NAME("ev67")
 
 void alpha_cpu_list(FILE *f, fprintf_function cpu_fprintf);
 /* you can call this signal handler from your SIGBUS and SIGSEGV