From: "Philippe Mathieu-Daudé" <philmd@oss.qualcomm.com>
To: qemu-devel@nongnu.org
Cc: qemu-s390x@nongnu.org, "Peter Maydell" <peter.maydell@linaro.org>,
"Alex Bennée" <alex.bennee@linaro.org>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Xiaoyao Li" <xiaoyao.li@intel.com>,
"Chao Liu" <chao.liu.zevorn@gmail.com>,
"Zhao Liu" <zhao1.liu@intel.com>,
"Daniel Henrique Barboza" <daniel.barboza@oss.qualcomm.com>,
qemu-ppc@nongnu.org,
"Richard Henderson" <richard.henderson@linaro.org>
Subject: [PATCH 29/33] cpu: Move CPUWatchpoint definition to 'exec/watchpoint.h'
Date: Wed, 1 Jul 2026 00:00:56 +0200 [thread overview]
Message-ID: <20260630220100.1289-30-philmd@oss.qualcomm.com> (raw)
In-Reply-To: <20260630220100.1289-1-philmd@oss.qualcomm.com>
Define CPUWatchpoint in "exec/watchpoint.h", including this
header where appropriate.
Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
---
include/accel/tcg/cpu-ops.h | 1 +
include/exec/breakpoint.h | 9 ---------
include/exec/watchpoint.h | 12 ++++++++++++
target/arm/internals.h | 1 +
gdbstub/system.c | 1 +
target/arm/hyp_gdbstub.c | 1 +
target/i386/kvm/kvm.c | 1 +
target/ppc/kvm.c | 1 +
target/s390x/kvm/kvm.c | 1 +
9 files changed, 19 insertions(+), 9 deletions(-)
diff --git a/include/accel/tcg/cpu-ops.h b/include/accel/tcg/cpu-ops.h
index 568d82cdd32..d5994781c39 100644
--- a/include/accel/tcg/cpu-ops.h
+++ b/include/accel/tcg/cpu-ops.h
@@ -20,6 +20,7 @@
#include "exec/memop.h"
#include "exec/mmu-access-type.h"
#include "exec/vaddr.h"
+#include "exec/watchpoint.h"
#include "accel/tcg/tb-cpu-state.h"
#include "tcg/tcg-mo.h"
diff --git a/include/exec/breakpoint.h b/include/exec/breakpoint.h
index 0c3cc0c8ff3..9d0dd89e7c9 100644
--- a/include/exec/breakpoint.h
+++ b/include/exec/breakpoint.h
@@ -33,13 +33,4 @@ typedef struct CPUBreakpoint {
QTAILQ_ENTRY(CPUBreakpoint) entry;
} CPUBreakpoint;
-typedef struct CPUWatchpoint {
- vaddr vaddr;
- vaddr len;
- vaddr hitaddr;
- MemTxAttrs hitattrs;
- int flags; /* BP_* */
- QTAILQ_ENTRY(CPUWatchpoint) entry;
-} CPUWatchpoint;
-
#endif
diff --git a/include/exec/watchpoint.h b/include/exec/watchpoint.h
index ba148eff3d1..7b72de35aa5 100644
--- a/include/exec/watchpoint.h
+++ b/include/exec/watchpoint.h
@@ -8,7 +8,19 @@
#ifndef EXEC_WATCHPOINT_H
#define EXEC_WATCHPOINT_H
+#include "qemu/queue.h"
#include "exec/breakpoint.h"
+#include "exec/memattrs.h"
+#include "exec/vaddr.h"
+
+typedef struct CPUWatchpoint {
+ vaddr vaddr;
+ vaddr len;
+ vaddr hitaddr;
+ MemTxAttrs hitattrs;
+ BreakpointFlags flags;
+ QTAILQ_ENTRY(CPUWatchpoint) entry;
+} CPUWatchpoint;
int cpu_watchpoint_insert(CPUState *cpu, vaddr addr, vaddr len,
BreakpointFlags flags, CPUWatchpoint **watchpoint);
diff --git a/target/arm/internals.h b/target/arm/internals.h
index 067c3f2b8bb..72ef3a2bf9c 100644
--- a/target/arm/internals.h
+++ b/target/arm/internals.h
@@ -29,6 +29,7 @@
#include "exec/vaddr.h"
#include "exec/breakpoint.h"
#include "exec/memop.h"
+#include "exec/watchpoint.h"
#include "gdbstub/enums.h"
#ifdef CONFIG_TCG
#include "accel/tcg/tb-cpu-state.h"
diff --git a/gdbstub/system.c b/gdbstub/system.c
index 108fe4bafb7..3dccd31cbc0 100644
--- a/gdbstub/system.c
+++ b/gdbstub/system.c
@@ -19,6 +19,7 @@
#include "gdbstub/syscalls.h"
#include "gdbstub/commands.h"
#include "exec/hwaddr.h"
+#include "exec/watchpoint.h"
#include "accel/accel-ops.h"
#include "accel/accel-cpu-ops.h"
#include "system/address-spaces.h"
diff --git a/target/arm/hyp_gdbstub.c b/target/arm/hyp_gdbstub.c
index dda6946ddaa..62dd91169dd 100644
--- a/target/arm/hyp_gdbstub.c
+++ b/target/arm/hyp_gdbstub.c
@@ -10,6 +10,7 @@
*/
#include "qemu/osdep.h"
+#include "exec/watchpoint.h"
#include "cpu.h"
#include "internals.h"
#include "gdbstub/enums.h"
diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c
index 1e09155e92c..372781ae715 100644
--- a/target/i386/kvm/kvm.c
+++ b/target/i386/kvm/kvm.c
@@ -70,6 +70,7 @@
#include "migration/blocker.h"
#include "exec/memattrs.h"
#include "exec/target_page.h"
+#include "exec/watchpoint.h"
#include "trace.h"
#include CONFIG_DEVICES
diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c
index 6bdfbbd68d6..85b15602396 100644
--- a/target/ppc/kvm.c
+++ b/target/ppc/kvm.c
@@ -41,6 +41,7 @@
#include "trace.h"
#include "gdbstub/enums.h"
#include "exec/memattrs.h"
+#include "exec/watchpoint.h"
#include "system/ramblock.h"
#include "system/hostmem.h"
#include "qemu/cutils.h"
diff --git a/target/s390x/kvm/kvm.c b/target/s390x/kvm/kvm.c
index 195e39df032..bb329883c97 100644
--- a/target/s390x/kvm/kvm.c
+++ b/target/s390x/kvm/kvm.c
@@ -49,6 +49,7 @@
#include "hw/s390x/ipl.h"
#include "hw/s390x/ebcdic.h"
#include "exec/memattrs.h"
+#include "exec/watchpoint.h"
#include "hw/s390x/s390-virtio-ccw.h"
#include "hw/s390x/s390-hypercall.h"
#include "target/s390x/kvm/pv.h"
--
2.53.0
next prev parent reply other threads:[~2026-06-30 22:07 UTC|newest]
Thread overview: 93+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-30 22:00 [PATCH 00/33] accel: Unassorted cleanups around debugging Philippe Mathieu-Daudé
2026-06-30 22:00 ` [PATCH 01/33] cpu: Constify CPUState::cc (cached CPUClass pointer) Philippe Mathieu-Daudé
2026-07-02 13:16 ` Daniel Henrique Barboza
2026-07-02 16:08 ` Richard Henderson
2026-07-03 0:41 ` Chao Liu
2026-06-30 22:00 ` [PATCH 02/33] target/i386: Remove duplicate tlb_flush() call in cpu_post_load() Philippe Mathieu-Daudé
2026-07-02 16:27 ` Richard Henderson
2026-07-03 0:42 ` Chao Liu
2026-06-30 22:00 ` [PATCH 03/33] accel/tcg: Restrict tlb_protect/unprotect_code() to TCG Philippe Mathieu-Daudé
2026-07-02 13:17 ` Daniel Henrique Barboza
2026-07-02 16:29 ` Richard Henderson
2026-07-03 3:13 ` Chao Liu
2026-06-30 22:00 ` [PATCH 04/33] accel/hvf: Remove left-over comment Philippe Mathieu-Daudé
2026-07-02 13:36 ` Daniel Henrique Barboza
2026-07-02 16:29 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 05/33] accel/mshv: Replace @dirty field by generic CPUState::vcpu_dirty field Philippe Mathieu-Daudé
2026-07-02 13:00 ` Philippe Mathieu-Daudé
2026-07-02 13:41 ` Magnus Kulke
2026-07-02 16:56 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 06/33] gdbstub: Add trace event for STEP packet handler Philippe Mathieu-Daudé
2026-07-02 13:18 ` Daniel Henrique Barboza
2026-07-02 13:25 ` Alex Bennée
2026-06-30 22:00 ` [PATCH 07/33] gdbstub: Only return E22 when reverse GDB is not supported Philippe Mathieu-Daudé
2026-07-02 13:18 ` Daniel Henrique Barboza
2026-07-02 13:26 ` Alex Bennée
2026-06-30 22:00 ` [PATCH 08/33] accel/kvm: Always define AccelOpsClass::supports_guest_debug Philippe Mathieu-Daudé
2026-07-02 13:19 ` Daniel Henrique Barboza
2026-07-02 17:16 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 09/33] accel/kvm: Simplify kvm_init() w.r.t. TARGET_KVM_HAVE_GUEST_DEBUG Philippe Mathieu-Daudé
2026-07-02 17:18 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 10/33] accel: Change gdbstub_supported_sstep_flags() -> get_gdbstub_config() Philippe Mathieu-Daudé
2026-07-02 13:50 ` Alex Bennée
2026-07-02 13:58 ` Philippe Mathieu-Daudé
2026-06-30 22:00 ` [PATCH 11/33] gdbstub: Store @can_reverse in GDBState Philippe Mathieu-Daudé
2026-07-02 13:20 ` Daniel Henrique Barboza
2026-06-30 22:00 ` [PATCH 12/33] gdbstub: Make default replay_mode value explicit in stubs Philippe Mathieu-Daudé
2026-07-02 17:21 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 13/33] accel: Have get_gdbstub_config() return @can_reverse value Philippe Mathieu-Daudé
2026-06-30 22:00 ` [PATCH 14/33] accel: Move supports_guest_debug() declaration to AccelClass Philippe Mathieu-Daudé
2026-07-02 17:29 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 15/33] accel/kvm: Hold have_guest_supported in KVMState Philippe Mathieu-Daudé
2026-07-02 13:22 ` Daniel Henrique Barboza
2026-07-02 17:37 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 16/33] accel/kvm: Hold gdbstub_sstep_flags " Philippe Mathieu-Daudé
2026-07-02 13:22 ` Daniel Henrique Barboza
2026-07-02 17:42 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 17/33] cpu: Move BREAKPOINT definitions to 'exec/breakpoint.h' Philippe Mathieu-Daudé
2026-07-02 13:24 ` Daniel Henrique Barboza
2026-07-02 17:43 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 18/33] cpu: Define BreakpointFlags type Philippe Mathieu-Daudé
2026-07-02 13:26 ` Daniel Henrique Barboza
2026-07-02 13:57 ` Philippe Mathieu-Daudé
2026-07-02 17:44 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 19/33] accel: Remove unnecessary 'inline' qualifier in remove_all_breakpoints Philippe Mathieu-Daudé
2026-07-02 13:27 ` Daniel Henrique Barboza
2026-07-02 17:45 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 20/33] gdbstub/user: Directly call gdb_breakpoint_remove_all() in user mode Philippe Mathieu-Daudé
2026-07-02 13:27 ` Daniel Henrique Barboza
2026-07-02 17:46 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 21/33] gdbstub: Reduce @type variable scope Philippe Mathieu-Daudé
2026-07-02 13:27 ` Daniel Henrique Barboza
2026-07-02 17:47 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 22/33] gdbstub: Introduce GdbBreakpointType enumerator Philippe Mathieu-Daudé
2026-07-02 13:29 ` Daniel Henrique Barboza
2026-07-02 13:53 ` Philippe Mathieu-Daudé
2026-07-02 17:50 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 23/33] accel: Use GdbBreakpointType enum Philippe Mathieu-Daudé
2026-07-02 13:31 ` Daniel Henrique Barboza
2026-07-02 17:52 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 24/33] target/arm: Inline check_watchpoints() in arm_debug_check_watchpoint() Philippe Mathieu-Daudé
2026-07-02 17:53 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 25/33] target/arm: Factor arm_check_watchpoint_hit() out Philippe Mathieu-Daudé
2026-07-02 18:02 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 26/33] target/xtensa: Move watchpoints handling to check_hw_watchpoints() Philippe Mathieu-Daudé
2026-07-02 18:06 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 27/33] target/ppc: Ensure TCG is used in ppc_update_daw() Philippe Mathieu-Daudé
2026-07-02 13:34 ` Daniel Henrique Barboza
2026-06-30 22:00 ` [PATCH 28/33] accel/tcg: Improve docstrings around TCGCPUOps::*watchpoint* handlers Philippe Mathieu-Daudé
2026-07-02 13:34 ` Daniel Henrique Barboza
2026-07-02 18:04 ` Richard Henderson
2026-06-30 22:00 ` Philippe Mathieu-Daudé [this message]
2026-07-02 18:06 ` [PATCH 29/33] cpu: Move CPUWatchpoint definition to 'exec/watchpoint.h' Richard Henderson
2026-06-30 22:00 ` [PATCH 30/33] cpu: Better name cpu_single_step() trace event Philippe Mathieu-Daudé
2026-07-02 13:35 ` Daniel Henrique Barboza
2026-06-30 22:00 ` [PATCH 31/33] cpu: Introduce cpu_single_stepping() helper Philippe Mathieu-Daudé
2026-07-02 18:11 ` Richard Henderson
2026-06-30 22:00 ` [PATCH 32/33] cpu: Rename CPUState @singlestep_enabled -> @singlestep_flags Philippe Mathieu-Daudé
2026-07-02 18:11 ` Richard Henderson
2026-07-03 1:27 ` Xiaoyao Li
2026-07-03 1:50 ` Philippe Mathieu-Daudé
2026-06-30 22:01 ` [PATCH 33/33] cpu: Only check SSTEP_ENABLE flag in cpu_single_stepping() Philippe Mathieu-Daudé
2026-07-02 13:36 ` Daniel Henrique Barboza
2026-07-02 18:11 ` Richard Henderson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260630220100.1289-30-philmd@oss.qualcomm.com \
--to=philmd@oss.qualcomm.com \
--cc=alex.bennee@linaro.org \
--cc=chao.liu.zevorn@gmail.com \
--cc=daniel.barboza@oss.qualcomm.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=richard.henderson@linaro.org \
--cc=xiaoyao.li@intel.com \
--cc=zhao1.liu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.