BSD 4_4 release
[unix-history] / usr / src / lib / libc / sys / mmap.2
index accf7bf..1c0d84a 100644 (file)
@@ -1,11 +1,37 @@
-.\" Copyright (c) 1991 Regents of the University of California.
-.\" All rights reserved.
+.\" Copyright (c) 1991, 1993
+.\"    The Regents of the University of California.  All rights reserved.
 .\"
 .\"
-.\" %sccs.include.redist.man%
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\" 1. Redistributions of source code must retain the above copyright
+.\"    notice, this list of conditions and the following disclaimer.
+.\" 2. Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in the
+.\"    documentation and/or other materials provided with the distribution.
+.\" 3. All advertising materials mentioning features or use of this software
+.\"    must display the following acknowledgement:
+.\"    This product includes software developed by the University of
+.\"    California, Berkeley and its contributors.
+.\" 4. Neither the name of the University nor the names of its contributors
+.\"    may be used to endorse or promote products derived from this software
+.\"    without specific prior written permission.
 .\"
 .\"
-.\"    @(#)mmap.2      6.3 (Berkeley) %G%
+.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+.\" SUCH DAMAGE.
 .\"
 .\"
-.Dd ""
+.\"    @(#)mmap.2      8.1 (Berkeley) 6/4/93
+.\"
+.Dd "June 4, 1993"
 .Dt MMAP 2
 .Os BSD 4
 .Sh NAME
 .Dt MMAP 2
 .Os BSD 4
 .Sh NAME
@@ -15,7 +41,7 @@
 .Fd #include <sys/types.h>
 .Fd #include <sys/mman.h>
 .Ft caddr_t
 .Fd #include <sys/types.h>
 .Fd #include <sys/mman.h>
 .Ft caddr_t
-.Fn mmap "caddr_t addr" "int len" "int prot" "int flags" "int fd" "off_t offset"
+.Fn mmap "caddr_t addr" "size_t len" "int prot" "int flags" "int fd" "off_t offset"
 .Sh DESCRIPTION
 The
 .Nm mmap
 .Sh DESCRIPTION
 The
 .Nm mmap
@@ -81,8 +107,8 @@ The file descriptor used for creating
 regions is used only for
 naming, and may be specified as \-1 if no name is associated with the
 region.
 regions is used only for
 naming, and may be specified as \-1 if no name is associated with the
 region.
-.It Dv MAP_FILE
-Mapped from a regular file or character-special device memory.
+.\".It Dv MAP_FILE
+.\"Mapped from a regular file or character-special device memory.
 .It Dv MAP_FIXED
 Do not permit the system to select a different address than the one
 specified.
 .It Dv MAP_FIXED
 Do not permit the system to select a different address than the one
 specified.
@@ -154,14 +180,14 @@ was not open for writing.
 .It Bq Er EBADF
 .Fa Fd
 is not a valid open file descriptor.
 .It Bq Er EBADF
 .Fa Fd
 is not a valid open file descriptor.
-.It Bq Er EINVAL
-One of
-.Dv MAP_ANON
-or
-.Dv MAP_FILE
-was not specified as part of the
-.Fa flags
-parameter.
+.\".It Bq Er EINVAL
+.\"One of
+.\".Dv MAP_ANON
+.\"or
+.\".Dv MAP_FILE
+.\"was not specified as part of the
+.\".Fa flags
+.\"parameter.
 .Dv MAP_FIXED
 was specified and the
 .I addr
 .Dv MAP_FIXED
 was specified and the
 .I addr