aboutsummaryrefslogtreecommitdiff
path: root/target/m68k/cpu.h
diff options
context:
space:
mode:
authorIgor Mammedov <imammedo@redhat.com>2017-08-24 18:31:34 +0200
committerEduardo Habkost <ehabkost@redhat.com>2017-09-01 11:54:24 -0300
commitf47cf4e31cac4e670e26226b549c379c982e223a (patch)
treee68ee0bc9a917dce78b6f6078d4f457c6b098e58 /target/m68k/cpu.h
parent8fc24ad5dd081e5655ad0e87fbea2e0812235f5a (diff)
m68k: replace cpu_m68k_init() with cpu_generic_init()
call register_m68k_insns() at realize time which makes cpu_m68k_init() typical object creation function. As result we can replace it with cpu_generic_init() which does the same job, reducing code duplication a bit. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Tested-by: Thomas Huth <huth@tuxfamily.org> Acked-by: Laurent Vivier <laurent@vivier.eu> Message-Id: <1503592308-93913-12-git-send-email-imammedo@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'target/m68k/cpu.h')
-rw-r--r--target/m68k/cpu.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/target/m68k/cpu.h b/target/m68k/cpu.h
index 38a7e11b92..d9365476e5 100644
--- a/target/m68k/cpu.h
+++ b/target/m68k/cpu.h
@@ -163,7 +163,6 @@ int m68k_cpu_gdb_write_register(CPUState *cpu, uint8_t *buf, int reg);
void m68k_tcg_init(void);
void m68k_cpu_init_gdb(M68kCPU *cpu);
-M68kCPU *cpu_m68k_init(const char *cpu_model);
/* you can call this signal handler from your SIGBUS and SIGSEGV
signal handlers to inform the virtual CPU of exceptions. non zero
is returned if the signal was handled by the virtual CPU. */
@@ -322,7 +321,7 @@ void register_m68k_insns (CPUM68KState *env);
#define TARGET_PHYS_ADDR_SPACE_BITS 32
#define TARGET_VIRT_ADDR_SPACE_BITS 32
-#define cpu_init(cpu_model) CPU(cpu_m68k_init(cpu_model))
+#define cpu_init(cpu_model) cpu_generic_init(TYPE_M68K_CPU, cpu_model)
#define cpu_signal_handler cpu_m68k_signal_handler
#define cpu_list m68k_cpu_list