Skip to content
Snippets Groups Projects
Commit 5dcf6334 authored by Alex Bennée's avatar Alex Bennée
Browse files

gdbstub: use a better signal when we halt for IO reasons


The gdb description GDB_SIGNAL_IO is "I/O possible" and by default gdb
will try and restart the guest, getting us nowhere. Report
GDB_SIGNAL_STOP instead which should at least halt the session at the
failure point.

Reviewed-by: default avatarLuis Machado <luis.machado@arm.com>
Reviewed-by: default avatarRichard Henderson <richard.henderson@linaro.org>
Acked-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: default avatarAlex Bennée <alex.bennee@linaro.org>
Message-Id: <20231201093633.2551497-2-alex.bennee@linaro.org>
parent abf635dd
No related branches found
No related tags found
No related merge requests found
......@@ -24,6 +24,7 @@ enum {
GDB_SIGNAL_TRAP = 5,
GDB_SIGNAL_ABRT = 6,
GDB_SIGNAL_ALRM = 14,
GDB_SIGNAL_STOP = 17,
GDB_SIGNAL_IO = 23,
GDB_SIGNAL_XCPU = 24,
GDB_SIGNAL_UNKNOWN = 143
......
......@@ -183,7 +183,7 @@ static void gdb_vm_state_change(void *opaque, bool running, RunState state)
break;
case RUN_STATE_IO_ERROR:
trace_gdbstub_hit_io_error();
ret = GDB_SIGNAL_IO;
ret = GDB_SIGNAL_STOP;
break;
case RUN_STATE_WATCHDOG:
trace_gdbstub_hit_watchdog();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment