aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/kgdb.c
diff options
context:
space:
mode:
authorJason Wessel <jason.wessel@windriver.com>2009-04-27 14:20:21 -0400
committerJason Wessel <jason.wessel@windriver.com>2009-12-11 09:43:19 -0500
commitd625e9c0d706eb43afbf52634d5cecacae1d57cc (patch)
tree080cb5ced15c3a0235fc270e9bae2fe8a904bd11 /kernel/kgdb.c
parent8097551d9ab9b9e3630694ad1bc6e12c597c515e (diff)
kgdb: continue and warn on signal passing from gdb
On some architectures for the segv trap, gdb wants to pass the signal back on continue. For kgdb this is not the default behavior, because it can cause the kernel to crash if you arbitrarily pass back a exception outside of kgdb. Instead of causing instability, pass a message back to gdb about the supported kgdb signal passing and execute a standard kgdb continue operation. Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Diffstat (limited to 'kernel/kgdb.c')
-rw-r--r--kernel/kgdb.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/kernel/kgdb.c b/kernel/kgdb.c
index ca21fe98e8de..8584eac55e30 100644
--- a/kernel/kgdb.c
+++ b/kernel/kgdb.c
@@ -1210,8 +1210,10 @@ static int gdb_cmd_exception_pass(struct kgdb_state *ks)
1210 return 1; 1210 return 1;
1211 1211
1212 } else { 1212 } else {
1213 error_packet(remcom_out_buffer, -EINVAL); 1213 kgdb_msg_write("KGDB only knows signal 9 (pass)"
1214 return 0; 1214 " and 15 (pass and disconnect)\n"
1215 "Executing a continue without signal passing\n", 0);
1216 remcom_in_buffer[0] = 'c';
1215 } 1217 }
1216 1218
1217 /* Indicate fall through */ 1219 /* Indicate fall through */