projects
/
wrapfs-2.6.38.y.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5b0660c
)
kgdb: Prevent infinite recursive entries to the debugger
author
Douglas Anderson
<dianders@chromium.org>
Thu, 7 May 2020 20:08:44 +0000
(13:08 -0700)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Sat, 20 Jun 2020 08:24:14 +0000
(10:24 +0200)
[ Upstream commit
3ca676e4ca60d1834bb77535dafe24169cadacef
]
If we detect that we recursively entered the debugger we should hack
our I/O ops to NULL so that the panic() in the next line won't
actually cause another recursion into the debugger. The first line of
kgdb_panic() will check this and return.
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
Link:
https://lore.kernel.org/r/20200507130644.v4.6.I89de39f68736c9de610e6f241e68d8dbc44bc266@changeid
Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
kernel/debug/debug_core.c
patch
|
blob
|
history
diff --git
a/kernel/debug/debug_core.c
b/kernel/debug/debug_core.c
index 79517e5549f119aff663ff5572507c70671a2b41..9c939c6bf21cba04cacb38a3315a8a253e769bba 100644
(file)
--- a/
kernel/debug/debug_core.c
+++ b/
kernel/debug/debug_core.c
@@
-443,6
+443,7
@@
static int kgdb_reenter_check(struct kgdb_state *ks)
if (exception_level > 1) {
dump_stack();
+ kgdb_io_module_registered = false;
panic("Recursive entry to debugger");
}