svn commit: r229187 - in stable/8/sys: amd64/amd64 i386/i386

Konstantin Belousov kib at FreeBSD.org
Sun Jan 1 18:59:36 UTC 2012


Author: kib
Date: Sun Jan  1 18:59:35 2012
New Revision: 229187
URL: http://svn.freebsd.org/changeset/base/229187

Log:
  MFC r227394:
  Stopped process may legitimately have some threads sleeping and not
  suspended, if the sleep is uninterruptible.
  
  MFC r227442:
  Weaken the part of assertions added in the r227394. Only check that the
  process state is stopped.

Modified:
  stable/8/sys/amd64/amd64/machdep.c
  stable/8/sys/i386/i386/machdep.c
Directory Properties:
  stable/8/sys/   (props changed)

Modified: stable/8/sys/amd64/amd64/machdep.c
==============================================================================
--- stable/8/sys/amd64/amd64/machdep.c	Sun Jan  1 18:54:29 2012	(r229186)
+++ stable/8/sys/amd64/amd64/machdep.c	Sun Jan  1 18:59:35 2012	(r229187)
@@ -1986,7 +1986,8 @@ int
 fill_fpregs(struct thread *td, struct fpreg *fpregs)
 {
 
-	KASSERT(td == curthread || TD_IS_SUSPENDED(td),
+	KASSERT(td == curthread || TD_IS_SUSPENDED(td) ||
+	    P_SHOULDSTOP(td->td_proc),
 	    ("not suspended thread %p", td));
 	fpugetregs(td);
 	fill_fpregs_xmm(&td->td_pcb->pcb_user_save, fpregs);

Modified: stable/8/sys/i386/i386/machdep.c
==============================================================================
--- stable/8/sys/i386/i386/machdep.c	Sun Jan  1 18:54:29 2012	(r229186)
+++ stable/8/sys/i386/i386/machdep.c	Sun Jan  1 18:59:35 2012	(r229187)
@@ -3220,7 +3220,8 @@ int
 fill_fpregs(struct thread *td, struct fpreg *fpregs)
 {
 
-	KASSERT(td == curthread || TD_IS_SUSPENDED(td),
+	KASSERT(td == curthread || TD_IS_SUSPENDED(td) ||
+	    P_SHOULDSTOP(td->td_proc),
 	    ("not suspended thread %p", td));
 #ifdef DEV_NPX
 	npxgetregs(td);


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