Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Jun 2009 17:04:39 +0000 (UTC)
From:      Alan Cox <alc@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r193842 - head/sys/vm
Message-ID:  <200906091704.n59H4dMt078075@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: alc
Date: Tue Jun  9 17:04:39 2009
New Revision: 193842
URL: http://svn.freebsd.org/changeset/base/193842

Log:
  Eliminate an unnecessary restriction on the vm object type from
  vm_map_pmap_enter().  The immediate effect of this change is that automatic
  prefaulting by mmap() for small mappings is performed on POSIX shared memory
  objects just the same as it is on ordinary files.

Modified:
  head/sys/vm/vm_map.c

Modified: head/sys/vm/vm_map.c
==============================================================================
--- head/sys/vm/vm_map.c	Tue Jun  9 16:32:29 2009	(r193841)
+++ head/sys/vm/vm_map.c	Tue Jun  9 17:04:39 2009	(r193842)
@@ -1643,11 +1643,9 @@ vm_map_pmap_enter(vm_map_t map, vm_offse
 
 	psize = atop(size);
 
-	if (object->type != OBJT_VNODE ||
-	    ((flags & MAP_PREFAULT_PARTIAL) && (psize > MAX_INIT_PT) &&
-	     (object->resident_page_count > MAX_INIT_PT))) {
+	if ((flags & MAP_PREFAULT_PARTIAL) && psize > MAX_INIT_PT &&
+	    object->resident_page_count > MAX_INIT_PT)
 		goto unlock_return;
-	}
 
 	if (psize + pindex > object->size) {
 		if (object->size < pindex)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906091704.n59H4dMt078075>