fix misplaced schedlock

Submitted by:	davidxu@freebsd.org
This commit is contained in:
julian 2002-09-07 01:48:53 +00:00
parent ec9cab8da4
commit d191c82c92
2 changed files with 2 additions and 2 deletions

View File

@ -742,9 +742,9 @@ thread_suspend_check(int return_instead)
psignal(p->p_pptr, SIGCHLD);
}
PROC_UNLOCK(p->p_pptr);
mtx_lock_spin(&sched_lock);
}
mtx_assert(&Giant, MA_NOTOWNED);
mtx_lock_spin(&sched_lock);
p->p_suspcount++;
td->td_state = TDS_SUSPENDED;
TAILQ_INSERT_TAIL(&p->p_suspended, td, td_runq);

View File

@ -742,9 +742,9 @@ thread_suspend_check(int return_instead)
psignal(p->p_pptr, SIGCHLD);
}
PROC_UNLOCK(p->p_pptr);
mtx_lock_spin(&sched_lock);
}
mtx_assert(&Giant, MA_NOTOWNED);
mtx_lock_spin(&sched_lock);
p->p_suspcount++;
td->td_state = TDS_SUSPENDED;
TAILQ_INSERT_TAIL(&p->p_suspended, td, td_runq);