aboutsummaryrefslogtreecommitdiff
path: root/exec.c
diff options
context:
space:
mode:
authorAndreas Färber <afaerber@suse.de>2013-06-21 20:20:45 +0200
committerAndreas Färber <afaerber@suse.de>2013-07-23 02:41:32 +0200
commited2803da58355413447f8c7c681a76873168114f (patch)
tree3772ea93bce05d67ccbd4194eb77173dc46a5706 /exec.c
parent801c4c287b7d85fe8447900f78a9a6ab89d00271 (diff)
cpu: Move singlestep_enabled field from CPU_COMMON to CPUState
Prepares for changing cpu_single_step() argument to CPUState. Acked-by: Michael Walle <michael@walle.cc> (for lm32) Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'exec.c')
-rw-r--r--exec.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/exec.c b/exec.c
index c8658c6f9d..30b676d7e5 100644
--- a/exec.c
+++ b/exec.c
@@ -588,11 +588,13 @@ void cpu_breakpoint_remove_all(CPUArchState *env, int mask)
void cpu_single_step(CPUArchState *env, int enabled)
{
#if defined(TARGET_HAS_ICE)
- if (env->singlestep_enabled != enabled) {
- env->singlestep_enabled = enabled;
- if (kvm_enabled())
+ CPUState *cpu = ENV_GET_CPU(env);
+
+ if (cpu->singlestep_enabled != enabled) {
+ cpu->singlestep_enabled = enabled;
+ if (kvm_enabled()) {
kvm_update_guest_debug(env, 0);
- else {
+ } else {
/* must flush all the translated code to avoid inconsistencies */
/* XXX: only flush what is necessary */
tb_flush(env);