From 376d7a2abb3e9097bbea079213b38d657e182561 Mon Sep 17 00:00:00 2001 From: Igor Mammedov Date: Mon, 9 Oct 2017 21:50:54 +0200 Subject: ppc: bamboo: use generic cpu_model parsing Signed-off-by: Igor Mammedov Acked-by: David Gibson Signed-off-by: David Gibson --- hw/ppc/ppc440_bamboo.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'hw') diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c index f92d47f28d..693c215108 100644 --- a/hw/ppc/ppc440_bamboo.c +++ b/hw/ppc/ppc440_bamboo.c @@ -182,11 +182,7 @@ static void bamboo_init(MachineState *machine) int success; int i; - /* Setup CPU. */ - if (machine->cpu_model == NULL) { - machine->cpu_model = "440EP"; - } - cpu = POWERPC_CPU(cpu_generic_init(TYPE_POWERPC_CPU, machine->cpu_model)); + cpu = POWERPC_CPU(cpu_create(machine->cpu_type)); env = &cpu->env; if (env->mmu_model != POWERPC_MMU_BOOKE) { @@ -297,6 +293,7 @@ static void bamboo_machine_init(MachineClass *mc) { mc->desc = "bamboo"; mc->init = bamboo_init; + mc->default_cpu_type = POWERPC_CPU_TYPE_NAME("440epb"); } DEFINE_MACHINE("bamboo", bamboo_machine_init) -- cgit v1.2.3