svn commit: r289414 - user/alc/PQ_LAUNDRY/sys/vm

Alan Cox alc at FreeBSD.org
Fri Oct 16 08:22:23 UTC 2015


Author: alc
Date: Fri Oct 16 08:22:21 2015
New Revision: 289414
URL: https://svnweb.freebsd.org/changeset/base/289414

Log:
  Revert r289357.

Modified:
  user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c

Modified: user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c
==============================================================================
--- user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c	Fri Oct 16 08:06:28 2015	(r289413)
+++ user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c	Fri Oct 16 08:22:21 2015	(r289414)
@@ -1080,12 +1080,11 @@ vm_pageout_launder1(struct vm_domain *vm
 		queues_locked = FALSE;
 
 		/*
-		 * Invalid pages cannot appear on a queue.  If
-		 * vm_pageout_fallback_object_lock() allowed a window
-		 * where the page could be invalidated, it should
-		 * detect this.
+		 * Invalid pages can be easily freed.  They cannot be
+		 * mapped; vm_page_free() asserts this.
 		 */
-		KASSERT(m->valid != 0, ("invalid page %p in laundry queue", m));
+		if (m->valid == 0)
+			goto free_page;
 
 		/*
 		 * If the page has been referenced and the object is not dead,
@@ -1144,6 +1143,7 @@ vm_pageout_launder1(struct vm_domain *vm
 		 * destroyed the object.
 		 */
 		if (m->dirty == 0) {
+free_page:
 			vm_page_free(m);
 			PCPU_INC(cnt.v_dfree);
 		} else if ((object->flags & OBJ_DEAD) == 0) {


More information about the svn-src-user mailing list