svn commit: r274339 - stable/10/sys/kern

Konstantin Belousov kib at FreeBSD.org
Mon Nov 10 09:11:24 UTC 2014


Author: kib
Date: Mon Nov 10 09:11:23 2014
New Revision: 274339
URL: https://svnweb.freebsd.org/changeset/base/274339

Log:
  MFC r274038:
  Clean up confusing comment.

Modified:
  stable/10/sys/kern/kern_thr.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/kern/kern_thr.c
==============================================================================
--- stable/10/sys/kern/kern_thr.c	Mon Nov 10 08:31:56 2014	(r274338)
+++ stable/10/sys/kern/kern_thr.c	Mon Nov 10 09:11:23 2014	(r274339)
@@ -317,10 +317,6 @@ sys_thr_exit(struct thread *td, struct t
 
 	PROC_LOCK(p);
 
-	/*
-	 * Shutting down last thread in the proc.  This will actually
-	 * call exit() in the trampoline when it returns.
-	 */
 	if (p->p_numthreads != 1) {
 		racct_sub(p, RACCT_NTHR, 1);
 		LIST_REMOVE(td, td_hash);
@@ -331,6 +327,12 @@ sys_thr_exit(struct thread *td, struct t
 		thread_exit();
 		/* NOTREACHED */
 	}
+
+	/*
+	 * Ignore attempts to shut down last thread in the proc.  This
+	 * will actually call _exit(2) in the usermode trampoline when
+	 * it returns.
+	 */
 	PROC_UNLOCK(p);
 	rw_wunlock(&tidhash_lock);
 	return (0);


More information about the svn-src-stable-10 mailing list