diff options
author | David Xu <davidxu@FreeBSD.org> | 2004-06-18 06:21:09 +0000 |
---|---|---|
committer | David Xu <davidxu@FreeBSD.org> | 2004-06-18 06:21:09 +0000 |
commit | 0aabef657e6e365ce7293d5d3872a782abc1f3bf (patch) | |
tree | 537d2a35c86bb808ea690a0ec08cf4bc2d6275f7 /sys/kern/kern_exit.c | |
parent | ec008e96a8849d8c3b0b2f67b346d356bc2ce89a (diff) | |
download | src-0aabef657e6e365ce7293d5d3872a782abc1f3bf.tar.gz src-0aabef657e6e365ce7293d5d3872a782abc1f3bf.zip |
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.
Notes
Notes:
svn path=/head/; revision=130675
Diffstat (limited to 'sys/kern/kern_exit.c')
-rw-r--r-- | sys/kern/kern_exit.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index f04615489bac..859612b06bb8 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) |