diff options
author | Gustavo Romero <gustavo.romero@linaro.org> | 2024-03-09 03:08:59 +0000 |
---|---|---|
committer | Alex Bennée <alex.bennee@linaro.org> | 2024-03-13 11:43:52 +0000 |
commit | f84e313e0278222eb88b9ca29311f0df71abd001 (patch) | |
tree | f6f7fca9201712d62bb6615280430f47484a8877 /include | |
parent | 4d6d8a05a0a6d102ca94e59a43804d65309921e3 (diff) |
gdbstub: Save target's siginfo
Save target's siginfo into gdbserver_state so it can be used later, for
example, in any stub that requires the target's si_signo and si_code.
This change affects only linux-user mode.
Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
Suggested-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20240309030901.1726211-4-gustavo.romero@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/gdbstub/user.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/gdbstub/user.h b/include/gdbstub/user.h index 4fc88f8a25..3b8358e3da 100644 --- a/include/gdbstub/user.h +++ b/include/gdbstub/user.h @@ -9,11 +9,15 @@ #ifndef GDBSTUB_USER_H #define GDBSTUB_USER_H +#define MAX_SIGINFO_LENGTH 128 + /** * gdb_handlesig() - yield control to gdb * @cpu: CPU * @sig: if non-zero, the signal number which caused us to stop * @reason: stop reason for stop reply packet or NULL + * @siginfo: target-specific siginfo struct + * @siginfo_len: target-specific siginfo struct length * * This function yields control to gdb, when a user-mode-only target * needs to stop execution. If @sig is non-zero, then we will send a @@ -25,7 +29,7 @@ * or 0 if no signal should be delivered, ie the signal that caused * us to stop should be ignored. */ -int gdb_handlesig(CPUState *, int, const char *); +int gdb_handlesig(CPUState *, int, const char *, void *, int); /** * gdb_signalled() - inform remote gdb of sig exit |