diff options
author | Andreas Färber <afaerber@suse.de> | 2013-06-28 19:41:07 +0200 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2013-07-23 02:41:32 +0200 |
commit | b42eab27beaefd5c9bf9353383d6403e0628c014 (patch) | |
tree | ded415a919492266321cbfe8091007e315d70edd /target-unicore32 | |
parent | a10b978c4246bf9af0e34505aba500d3e7f6c6c4 (diff) | |
download | qemu-b42eab27beaefd5c9bf9353383d6403e0628c014.zip qemu-b42eab27beaefd5c9bf9353383d6403e0628c014.tar.gz qemu-b42eab27beaefd5c9bf9353383d6403e0628c014.tar.bz2 |
target-unicore32: Implement CPUClass::set_pc()
This adds support for GDB's c addr (Continue) and s addr (Single Step).
Prepares for dropping cpu_pc_from_tb().
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'target-unicore32')
-rw-r--r-- | target-unicore32/cpu.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/target-unicore32/cpu.c b/target-unicore32/cpu.c index 6572f01..79f2292 100644 --- a/target-unicore32/cpu.c +++ b/target-unicore32/cpu.c @@ -16,6 +16,13 @@ #include "qemu-common.h" #include "migration/vmstate.h" +static void uc32_cpu_set_pc(CPUState *cs, vaddr value) +{ + UniCore32CPU *cpu = UNICORE32_CPU(cs); + + cpu->env.regs[31] = value; +} + static inline void set_feature(CPUUniCore32State *env, int feature) { env->features |= feature; @@ -131,6 +138,7 @@ static void uc32_cpu_class_init(ObjectClass *oc, void *data) cc->class_by_name = uc32_cpu_class_by_name; cc->do_interrupt = uc32_cpu_do_interrupt; cc->dump_state = uc32_cpu_dump_state; + cc->set_pc = uc32_cpu_set_pc; dc->vmsd = &vmstate_uc32_cpu; } |