aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2008-12-15 13:48:27 +0100
committerAvi Kivity <avi@redhat.com>2008-12-17 14:21:17 +0200
commitc2fcf85c448abf4c8a71cc8c5eec758b3b4098ec (patch)
treef424fccda36a79919ba2439070e8912478c5b6aa /gdbstub.h
parentPpc: sync with upstream qemu (diff)
downloadqemu-kvm-c2fcf85c448abf4c8a71cc8c5eec758b3b4098ec.tar.gz
qemu-kvm-c2fcf85c448abf4c8a71cc8c5eec758b3b4098ec.tar.bz2
qemu-kvm-c2fcf85c448abf4c8a71cc8c5eec758b3b4098ec.zip
Switch to new guest debug interface
This patch switches both libkvm as well as the qemu pieces over to the new guest debug interface. It comes with full support for software-based breakpoints (via guest code modification), hardware-assisted breakpoints and watchpoints (x86-only so far). Breakpoint management is done inside qemu-kvm, transparently to gdbstub and also avoiding that the gdb frontend takes over. This allows for running debuggers inside the guest while guest debugging it active, because the host can cleanly tell apart host- and guest-originated breakpoint events. Yet improvable are x86 corner cases when using single-step ("forgotten" debug flags on the guest's stack). And, of course, the yet empty non-x86 helper functions have to be populated. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'gdbstub.h')
-rw-r--r--gdbstub.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/gdbstub.h b/gdbstub.h
index 1ba7931f7..e17ac90f3 100644
--- a/gdbstub.h
+++ b/gdbstub.h
@@ -3,6 +3,13 @@
#define DEFAULT_GDBSTUB_PORT "1234"
+/* GDB breakpoint/watchpoint types */
+#define GDB_BREAKPOINT_SW 0
+#define GDB_BREAKPOINT_HW 1
+#define GDB_WATCHPOINT_WRITE 2
+#define GDB_WATCHPOINT_READ 3
+#define GDB_WATCHPOINT_ACCESS 4
+
typedef void (*gdb_syscall_complete_cb)(CPUState *env,
target_ulong ret, target_ulong err);