mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2025-02-25 20:36:56 +00:00
mips: call cpu_mips_realize_env() from mips_cpu_realizefn()
This changes the order between cpu_mips_realize_env() and cpu_exec_initfn(), but cpu_exec_initfn() don't have anything that depends on cpu_mips_realize_env() being called first. Backports commit df4dc10284e1d871db8adb512816a561473ffe3e from qemu
This commit is contained in:
parent
3257a8f8c3
commit
4729b633f1
|
@ -108,8 +108,11 @@ static void mips_cpu_reset(CPUState *s)
|
|||
static int mips_cpu_realizefn(struct uc_struct *uc, DeviceState *dev, Error **errp)
|
||||
{
|
||||
CPUState *cs = CPU(dev);
|
||||
MIPSCPU *cpu = MIPS_CPU(uc, dev);
|
||||
MIPSCPUClass *mcc = MIPS_CPU_GET_CLASS(uc, dev);
|
||||
|
||||
cpu_mips_realize_env(&cpu->env);
|
||||
|
||||
cpu_reset(cs);
|
||||
qemu_init_vcpu(cs);
|
||||
|
||||
|
|
|
@ -20740,8 +20740,6 @@ MIPSCPU *cpu_mips_init(struct uc_struct *uc, const char *cpu_model)
|
|||
env = &cpu->env;
|
||||
env->cpu_model = def;
|
||||
|
||||
cpu_mips_realize_env(env);
|
||||
|
||||
object_property_set_bool(uc, OBJECT(cpu), true, "realized", NULL);
|
||||
|
||||
return cpu;
|
||||
|
|
Loading…
Reference in a new issue