X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=target-openrisc%2Fcpu.c;h=3da5a7a8b11a60f1d27d07e01bdf5304ede981d8;hb=874ec3c5b3821bb964f9f37b2f930f2a9ce51652;hp=6d40f1b85e36f98f62eaa991bff54097cffea242;hpb=91b1df8cf9e1ecaa8679c9ea8713d1e25c28e6c4;p=qemu.git diff --git a/target-openrisc/cpu.c b/target-openrisc/cpu.c index 6d40f1b85..3da5a7a8b 100644 --- a/target-openrisc/cpu.c +++ b/target-openrisc/cpu.c @@ -20,6 +20,13 @@ #include "cpu.h" #include "qemu-common.h" +static void openrisc_cpu_set_pc(CPUState *cs, vaddr value) +{ + OpenRISCCPU *cpu = OPENRISC_CPU(cs); + + cpu->env.pc = value; +} + /* CPUClass::reset() */ static void openrisc_cpu_reset(CPUState *s) { @@ -146,7 +153,11 @@ static void openrisc_cpu_class_init(ObjectClass *oc, void *data) cc->class_by_name = openrisc_cpu_class_by_name; cc->do_interrupt = openrisc_cpu_do_interrupt; cc->dump_state = openrisc_cpu_dump_state; - device_class_set_vmsd(dc, &vmstate_openrisc_cpu); + cc->set_pc = openrisc_cpu_set_pc; +#ifndef CONFIG_USER_ONLY + cc->get_phys_page_debug = openrisc_cpu_get_phys_page_debug; + dc->vmsd = &vmstate_openrisc_cpu; +#endif } static void cpu_register(const OpenRISCCPUInfo *info)