aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorGustavo Romero <gustavo.romero@linaro.org>2024-07-05 09:40:44 +0100
committerAlex Bennée <alex.bennee@linaro.org>2024-07-05 12:35:23 +0100
commit2be4d5db1e50f5aabdeea6d1e63ef75cccd0bbdb (patch)
tree1ed2c76f8b69da757ef1104db39ecfed61f0132a /include
parent3ce0fc57a0e7d528ce0435c93205f9f6558c38ff (diff)
downloadqemu-2be4d5db1e50f5aabdeea6d1e63ef75cccd0bbdb.zip
qemu-2be4d5db1e50f5aabdeea6d1e63ef75cccd0bbdb.tar.gz
qemu-2be4d5db1e50f5aabdeea6d1e63ef75cccd0bbdb.tar.bz2
gdbstub: Pass CPU context to command handler
Allow passing the current CPU context to command handlers via user_ctx when the handler requires it. Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org> Message-Id: <20240628050850.536447-9-gustavo.romero@linaro.org> Reviewed-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20240705084047.857176-38-alex.bennee@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/gdbstub/commands.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/gdbstub/commands.h b/include/gdbstub/commands.h
index e51f276..f3058f9 100644
--- a/include/gdbstub/commands.h
+++ b/include/gdbstub/commands.h
@@ -54,6 +54,8 @@ typedef union GdbCmdVariant {
* "stop reply" packet. The list of commands that accept such response is
* defined at the GDB Remote Serial Protocol documentation. See:
* https://sourceware.org/gdb/onlinedocs/gdb/Stop-Reply-Packets.html#Stop-Reply-Packets.
+ *
+ * @need_cpu_context: Pass current CPU context to command handler via user_ctx.
*/
typedef struct GdbCmdParseEntry {
GdbCmdHandler handler;
@@ -61,6 +63,7 @@ typedef struct GdbCmdParseEntry {
bool cmd_startswith;
const char *schema;
bool allow_stop_reply;
+ bool need_cpu_context;
} GdbCmdParseEntry;
/**