summaryrefslogtreecommitdiff
path: root/lib/ubsan.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ubsan.c')
-rw-r--r--lib/ubsan.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/lib/ubsan.c b/lib/ubsan.c
index adf8dcf3c84e..ee14c46cac89 100644
--- a/lib/ubsan.c
+++ b/lib/ubsan.c
@@ -151,16 +151,7 @@ static void ubsan_epilogue(void)
current->in_ubsan--;
- if (panic_on_warn) {
- /*
- * This thread may hit another WARN() in the panic path.
- * Resetting this prevents additional WARN() from panicking the
- * system on this thread. Other threads are blocked by the
- * panic_mutex in panic().
- */
- panic_on_warn = 0;
- panic("panic_on_warn set ...\n");
- }
+ check_panic_on_warn("UBSAN");
}
static void handle_overflow(struct overflow_data *data, void *lhs,