From 70a732669be740b5518c07625a38b3e82a13f6d4 Mon Sep 17 00:00:00 2001 From: davidxu Date: Fri, 18 Jun 2004 06:21:09 +0000 Subject: Remove a bogus panic. It is possible more than one threads will be suspended in thread_suspend_check, after they are resumed, all threads will call thread_single, but only one can be success, others should retry and will exit in thread_suspend_check. --- sys/kern/kern_exit.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sys/kern/kern_exit.c') diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index f046154..859612b 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -133,6 +133,7 @@ exit1(struct thread *td, int rv) */ PROC_LOCK(p); if (p->p_flag & P_SA || p->p_numthreads > 1) { +retry: /* * First check if some other thread got here before us.. * if so, act apropriatly, (exit or suspend); @@ -154,7 +155,7 @@ exit1(struct thread *td, int rv) * thread exits. */ if (thread_single(SINGLE_EXIT)) - panic ("Exit: Single threading fouled up"); + goto retry; /* * All other activity in this process is now stopped. * Remove excess KSEs and KSEGRPS. XXXKSE (when we have them) -- cgit v1.1