From e4e5ed252d89a8812ed90fc0a28a48a9bc3ecd77 Mon Sep 17 00:00:00 2001 From: Marius Strobl Date: Mon, 31 Aug 2009 19:16:58 +0000 Subject: [PATCH] Add a temporary workaround which just lets init die instead of causing a panic if it is killed due to a unsolved stack overflow seen very late during shutdown on sparc64 when the gmirror worker process exists, which is a regression introduced in 8.0. Reviewed by: kib Approved by: re (rwatson) --- sys/kern/kern_exit.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index 36a074d0ef60..39b48e01bded 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -131,7 +131,12 @@ exit1(struct thread *td, int rv) mtx_assert(&Giant, MA_NOTOWNED); p = td->td_proc; - if (p == initproc) { + /* + * XXX in case we're rebooting we just let init die in order to + * work around an unsolved stack overflow seen very late during + * shutdown on sparc64 when the gmirror worker process exists. + */ + if (p == initproc && rebooting == 0) { printf("init died (signal %d, exit %d)\n", WTERMSIG(rv), WEXITSTATUS(rv)); panic("Going nowhere without my init!");