Date: Thu, 10 Mar 2005 11:14:57 GMT From: David Xu <davidxu@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 72829 for review Message-ID: <200503101114.j2ABEv6V031144@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=72829 Change 72829 by davidxu@davidxu_alona on 2005/03/10 11:14:32 only call sched_fork_ksegrp with sched_lock held. Affected files ... .. //depot/projects/davidxu_thread/src/sys/kern/kern_thr.c#11 edit Differences ... ==== //depot/projects/davidxu_thread/src/sys/kern/kern_thr.c#11 (text+ko) ==== @@ -163,14 +163,14 @@ td->td_proc->p_flag |= P_HADTHREADS; newtd->td_sigmask = td->td_sigmask; mtx_lock_spin(&sched_lock); - if (linkkg) { + if (linkkg) ksegrp_link(newkg, p); - sched_fork_ksegrp(td, newkg); - } thread_link(newtd, newkg); PROC_UNLOCK(p); /* let the scheduler know about these things. */ + if (linkkg) + sched_fork_ksegrp(td, newkg); sched_fork_thread(td, newtd); TD_SET_CAN_RUN(newtd); if ((uap->flags & THR_SUSPENDED) == 0)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200503101114.j2ABEv6V031144>