summary refs log tree commit diff stats
path: root/target/arm/machine.c
diff options
context:
space:
mode:
authorFabiano Rosas <farosas@suse.de>2023-02-17 17:11:27 -0300
committerPeter Maydell <peter.maydell@linaro.org>2023-02-27 13:27:04 +0000
commitfa05d1abb998a3272f97a70db2f8a01852ebc06c (patch)
treee07db4448984cd7ad9ff81744ca6ff623efdb76a /target/arm/machine.c
parent212154821e6dc400315a67ad8204f5e5c4b3023c (diff)
downloadfocaccia-qemu-fa05d1abb998a3272f97a70db2f8a01852ebc06c.tar.gz
focaccia-qemu-fa05d1abb998a3272f97a70db2f8a01852ebc06c.zip
target/arm: Wrap breakpoint/watchpoint updates with tcg_enabled
This is in preparation for restricting compilation of some parts of
debug_helper.c to TCG only.

Signed-off-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/arm/machine.c')
-rw-r--r--target/arm/machine.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/target/arm/machine.c b/target/arm/machine.c
index b4c3850570..fd6323f6d8 100644
--- a/target/arm/machine.c
+++ b/target/arm/machine.c
@@ -2,6 +2,7 @@
 #include "cpu.h"
 #include "qemu/error-report.h"
 #include "sysemu/kvm.h"
+#include "sysemu/tcg.h"
 #include "kvm_arm.h"
 #include "internals.h"
 #include "migration/cpu.h"
@@ -848,8 +849,10 @@ static int cpu_post_load(void *opaque, int version_id)
         return -1;
     }
 
-    hw_breakpoint_update_all(cpu);
-    hw_watchpoint_update_all(cpu);
+    if (tcg_enabled()) {
+        hw_breakpoint_update_all(cpu);
+        hw_watchpoint_update_all(cpu);
+    }
 
     /*
      * TCG gen_update_fp_context() relies on the invariant that