Date: Tue, 25 Oct 2011 23:29:36 +0000 (UTC) From: Alan Cox <alc@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r226766 - stable/8/lib/libc/sys Message-ID: <201110252329.p9PNTaEf021713@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: alc Date: Tue Oct 25 23:29:36 2011 New Revision: 226766 URL: http://svn.freebsd.org/changeset/base/226766 Log: MFC r211937 Add the MAP_PREFAULT_READ option to mmap(2). Modified: stable/8/lib/libc/sys/mmap.2 Directory Properties: stable/8/lib/libc/ (props changed) stable/8/lib/libc/stdtime/ (props changed) Modified: stable/8/lib/libc/sys/mmap.2 ============================================================================== --- stable/8/lib/libc/sys/mmap.2 Tue Oct 25 23:28:16 2011 (r226765) +++ stable/8/lib/libc/sys/mmap.2 Tue Oct 25 23:29:36 2011 (r226766) @@ -28,7 +28,7 @@ .\" @(#)mmap.2 8.4 (Berkeley) 5/11/95 .\" $FreeBSD$ .\" -.Dd July 26, 2009 +.Dd August 28, 2010 .Dt MMAP 2 .Os .Sh NAME @@ -207,6 +207,19 @@ implements a coherent file system buffer However, it may be used to associate dirty VM pages with file system buffers and thus cause them to be flushed to physical media sooner rather than later. +.It Dv MAP_PREFAULT_READ +Immediately update the calling process's lowest-level virtual address +translation structures, such as its page table, so that every memory +resident page within the region is mapped for read access. +Ordinarily these structures are updated lazily. +The effect of this option is to eliminate any soft faults that would +otherwise occur on the initial read accesses to the region. +Although this option does not preclude +.Fa prot +from including +.Dv PROT_WRITE , +it does not eliminate soft faults on the initial write accesses to the +region. .It Dv MAP_PRIVATE Modifications are private. .It Dv MAP_SHARED
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201110252329.p9PNTaEf021713>