OSDN Git Service

Update README
[linuxjm/LDP_man-pages.git] / original / man2 / mmap.2
1 .\" Copyright (C) 1996 Andries Brouwer <aeb@cwi.nl>
2 .\" and Copyright (C) 2006, 2007 Michael Kerrisk <mtk.manpages@gmail.com>
3 .\"
4 .\" %%%LICENSE_START(VERBATIM)
5 .\" Permission is granted to make and distribute verbatim copies of this
6 .\" manual provided the copyright notice and this permission notice are
7 .\" preserved on all copies.
8 .\"
9 .\" Permission is granted to copy and distribute modified versions of this
10 .\" manual under the conditions for verbatim copying, provided that the
11 .\" entire resulting derived work is distributed under the terms of a
12 .\" permission notice identical to this one.
13 .\"
14 .\" Since the Linux kernel and libraries are constantly changing, this
15 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
16 .\" responsibility for errors or omissions, or for damages resulting from
17 .\" the use of the information contained herein.  The author(s) may not
18 .\" have taken the same level of care in the production of this manual,
19 .\" which is licensed free of charge, as they might when working
20 .\" professionally.
21 .\"
22 .\" Formatted or processed versions of this manual, if unaccompanied by
23 .\" the source, must acknowledge the copyright and authors of this work.
24 .\" %%%LICENSE_END
25 .\"
26 .\" Modified 1997-01-31 by Eric S. Raymond <esr@thyrsus.com>
27 .\" Modified 2000-03-25 by Jim Van Zandt <jrv@vanzandt.mv.com>
28 .\" Modified 2001-10-04 by John Levon <moz@compsoc.man.ac.uk>
29 .\" Modified 2003-02-02 by Andi Kleen <ak@muc.de>
30 .\" Modified 2003-05-21 by Michael Kerrisk <mtk.manpages@gmail.com>
31 .\"     MAP_LOCKED works from 2.5.37
32 .\" Modified 2004-06-17 by Michael Kerrisk <mtk.manpages@gmail.com>
33 .\" Modified 2004-09-11 by aeb
34 .\" Modified 2004-12-08, from Eric Estievenart <eric.estievenart@free.fr>
35 .\" Modified 2004-12-08, mtk, formatting tidy-ups
36 .\" Modified 2006-12-04, mtk, various parts rewritten
37 .\" 2007-07-10, mtk, Added an example program.
38 .\" 2008-11-18, mtk, document MAP_STACK
39 .\"
40 .TH MMAP 2 2015-01-22 "Linux" "Linux Programmer's Manual"
41 .SH NAME
42 mmap, munmap \- map or unmap files or devices into memory
43 .SH SYNOPSIS
44 .nf
45 .B #include <sys/mman.h>
46 .sp
47 .BI "void *mmap(void *" addr ", size_t " length \
48 ", int " prot ", int " flags ,
49 .BI "           int " fd ", off_t " offset );
50 .BI "int munmap(void *" addr ", size_t " length );
51 .fi
52
53 See NOTES for information on feature test macro requirements.
54 .SH DESCRIPTION
55 .BR mmap ()
56 creates a new mapping in the virtual address space of
57 the calling process.
58 The starting address for the new mapping is specified in
59 .IR addr .
60 The
61 .I length
62 argument specifies the length of the mapping.
63
64 If
65 .I addr
66 is NULL,
67 then the kernel chooses the address at which to create the mapping;
68 this is the most portable method of creating a new mapping.
69 If
70 .I addr
71 is not NULL,
72 then the kernel takes it as a hint about where to place the mapping;
73 on Linux, the mapping will be created at a nearby page boundary.
74 .\" Before Linux 2.6.24, the address was rounded up to the next page
75 .\" boundary; since 2.6.24, it is rounded down!
76 The address of the new mapping is returned as the result of the call.
77
78 The contents of a file mapping (as opposed to an anonymous mapping; see
79 .B MAP_ANONYMOUS
80 below), are initialized using
81 .I length
82 bytes starting at offset
83 .I offset
84 in the file (or other object) referred to by the file descriptor
85 .IR fd .
86 .I offset
87 must be a multiple of the page size as returned by
88 .IR sysconf(_SC_PAGE_SIZE) .
89 .LP
90 The
91 .I prot
92 argument describes the desired memory protection of the mapping
93 (and must not conflict with the open mode of the file).
94 It is either
95 .B PROT_NONE
96 or the bitwise OR of one or more of the following flags:
97 .TP 1.1i
98 .B PROT_EXEC
99 Pages may be executed.
100 .TP
101 .B PROT_READ
102 Pages may be read.
103 .TP
104 .B PROT_WRITE
105 Pages may be written.
106 .TP
107 .B PROT_NONE
108 Pages may not be accessed.
109 .LP
110 The
111 .I flags
112 argument determines whether updates to the mapping
113 are visible to other processes mapping the same region,
114 and whether updates are carried through to the underlying file.
115 This behavior is determined by including exactly one
116 of the following values in
117 .IR flags :
118 .TP 1.1i
119 .B MAP_SHARED
120 Share this mapping.
121 Updates to the mapping are visible to other processes that map this file,
122 and are carried through to the underlying file.
123 The file may not actually be updated until
124 .BR msync (2)
125 or
126 .BR munmap ()
127 is called.
128 .TP
129 .B MAP_PRIVATE
130 Create a private copy-on-write mapping.
131 Updates to the mapping are not visible to other processes
132 mapping the same file, and are not carried through to
133 the underlying file.
134 It is unspecified whether changes made to the file after the
135 .BR mmap ()
136 call are visible in the mapped region.
137 .LP
138 Both of these flags are described in POSIX.1-2001.
139
140 In addition, zero or more of the following values can be ORed in
141 .IR flags :
142 .TP
143 .BR MAP_32BIT " (since Linux 2.4.20, 2.6)"
144 Put the mapping into the first 2 Gigabytes of the process address space.
145 This flag is supported only on x86-64, for 64-bit programs.
146 It was added to allow thread stacks to be allocated somewhere
147 in the first 2GB of memory,
148 so as to improve context-switch performance on some early
149 64-bit processors.
150 .\" See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
151 Modern x86-64 processors no longer have this performance problem,
152 so use of this flag is not required on those systems.
153 The
154 .B MAP_32BIT
155 flag is ignored when
156 .B MAP_FIXED
157 is set.
158 .TP
159 .B MAP_ANON
160 Synonym for
161 .BR MAP_ANONYMOUS .
162 Deprecated.
163 .TP
164 .B MAP_ANONYMOUS
165 The mapping is not backed by any file;
166 its contents are initialized to zero.
167 The
168 .I fd
169 and
170 .I offset
171 arguments are ignored;
172 however, some implementations require
173 .I fd
174 to be \-1 if
175 .B MAP_ANONYMOUS
176 (or
177 .BR MAP_ANON )
178 is specified,
179 and portable applications should ensure this.
180 The use of
181 .B MAP_ANONYMOUS
182 in conjunction with
183 .B MAP_SHARED
184 is supported on Linux only since kernel 2.4.
185 .TP
186 .B MAP_DENYWRITE
187 This flag is ignored.
188 .\" Introduced in 1.1.36, removed in 1.3.24.
189 (Long ago, it signaled that attempts to write to the underlying file
190 should fail with
191 .BR ETXTBUSY .
192 But this was a source of denial-of-service attacks.)
193 .TP
194 .B MAP_EXECUTABLE
195 This flag is ignored.
196 .\" Introduced in 1.1.38, removed in 1.3.24. Flag tested in proc_follow_link.
197 .\" (Long ago, it signaled that the underlying file is an executable.
198 .\" However, that information was not really used anywhere.)
199 .\" Linus talked about DOS related to MAP_EXECUTABLE, but he was thinking of
200 .\" MAP_DENYWRITE?
201 .TP
202 .B MAP_FILE
203 Compatibility flag.
204 Ignored.
205 .\" On some systems, this was required as the opposite of
206 .\" MAP_ANONYMOUS -- mtk, 1 May 2007
207 .TP
208 .B MAP_FIXED
209 Don't interpret
210 .I addr
211 as a hint: place the mapping at exactly that address.
212 .I addr
213 must be a multiple of the page size.
214 If the memory region specified by
215 .I addr
216 and
217 .I len
218 overlaps pages of any existing mapping(s), then the overlapped
219 part of the existing mapping(s) will be discarded.
220 If the specified address cannot be used,
221 .BR mmap ()
222 will fail.
223 Because requiring a fixed address for a mapping is less portable,
224 the use of this option is discouraged.
225 .TP
226 .B MAP_GROWSDOWN
227 Used for stacks.
228 Indicates to the kernel virtual memory system that the mapping
229 should extend downward in memory.
230 .TP
231 .BR MAP_HUGETLB " (since Linux 2.6.32)"
232 Allocate the mapping using "huge pages."
233 See the Linux kernel source file
234 .I Documentation/vm/hugetlbpage.txt
235 for further information.
236 .TP
237 .BR MAP_LOCKED " (since Linux 2.5.37)"
238 Lock the pages of the mapped region into memory in the manner of
239 .BR mlock (2).
240 This flag is ignored in older kernels.
241 .\" If set, the mapped pages will not be swapped out.
242 .TP
243 .BR MAP_NONBLOCK " (since Linux 2.5.46)"
244 Only meaningful in conjunction with
245 .BR MAP_POPULATE .
246 Don't perform read-ahead:
247 create page tables entries only for pages
248 that are already present in RAM.
249 Since Linux 2.6.23, this flag causes
250 .BR MAP_POPULATE
251 to do nothing.
252 One day the combination of
253 .BR MAP_POPULATE
254 and
255 .BR MAP_NONBLOCK
256 may be reimplemented.
257 .TP
258 .B MAP_NORESERVE
259 Do not reserve swap space for this mapping.
260 When swap space is reserved, one has the guarantee
261 that it is possible to modify the mapping.
262 When swap space is not reserved one might get
263 .B SIGSEGV
264 upon a write
265 if no physical memory is available.
266 See also the discussion of the file
267 .I /proc/sys/vm/overcommit_memory
268 in
269 .BR proc (5).
270 In kernels before 2.6, this flag had effect only for
271 private writable mappings.
272 .TP
273 .BR MAP_POPULATE " (since Linux 2.5.46)"
274 Populate (prefault) page tables for a mapping.
275 For a file mapping, this causes read-ahead on the file.
276 Later accesses to the mapping will not be blocked by page faults.
277 .BR MAP_POPULATE
278 is supported for private mappings only since Linux 2.6.23.
279 .TP
280 .BR MAP_STACK " (since Linux 2.6.27)"
281 Allocate the mapping at an address suitable for a process
282 or thread stack.
283 This flag is currently a no-op,
284 but is used in the glibc threading implementation so that
285 if some architectures require special treatment for stack allocations,
286 support can later be transparently implemented for glibc.
287 .\" See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
288 .\" commit cd98a04a59e2f94fa64d5bf1e26498d27427d5e7
289 .\" http://thread.gmane.org/gmane.linux.kernel/720412
290 .\" "pthread_create() slow for many threads; also time to revisit 64b
291 .\"  context switch optimization?"
292 .TP
293 .BR MAP_UNINITIALIZED " (since Linux 2.6.33)"
294 Don't clear anonymous pages.
295 This flag is intended to improve performance on embedded devices.
296 This flag is honored only if the kernel was configured with the
297 .B CONFIG_MMAP_ALLOW_UNINITIALIZED
298 option.
299 Because of the security implications,
300 that option is normally enabled only on embedded devices
301 (i.e., devices where one has complete control of the contents of user memory).
302 .LP
303 Of the above flags, only
304 .B MAP_FIXED
305 is specified in POSIX.1-2001.
306 However, most systems also support
307 .B MAP_ANONYMOUS
308 (or its synonym
309 .BR MAP_ANON ).
310 .LP
311 Some systems document the additional flags
312 .BR MAP_AUTOGROW ,
313 .BR MAP_AUTORESRV ,
314 .BR MAP_COPY ,
315 and
316 .BR MAP_LOCAL .
317 .LP
318 Memory mapped by
319 .BR mmap ()
320 is preserved across
321 .BR fork (2),
322 with the same attributes.
323 .LP
324 A file is mapped in multiples of the page size.
325 For a file that is not
326 a multiple of the page size, the remaining memory is zeroed when mapped,
327 and writes to that region are not written out to the file.
328 The effect of
329 changing the size of the underlying file of a mapping on the pages that
330 correspond to added or removed regions of the file is unspecified.
331 .SS munmap()
332 The
333 .BR munmap ()
334 system call deletes the mappings for the specified address range, and
335 causes further references to addresses within the range to generate
336 invalid memory references.
337 The region is also automatically unmapped
338 when the process is terminated.
339 On the other hand, closing the file
340 descriptor does not unmap the region.
341 .LP
342 The address
343 .I addr
344 must be a multiple of the page size.
345 All pages containing a part
346 of the indicated range are unmapped, and subsequent references
347 to these pages will generate
348 .BR SIGSEGV .
349 It is not an error if the
350 indicated range does not contain any mapped pages.
351 .SS Timestamps changes for file-backed mappings
352 For file-backed mappings, the
353 .I st_atime
354 field for the mapped file may be updated at any time between the
355 .BR mmap ()
356 and the corresponding unmapping; the first reference to a mapped
357 page will update the field if it has not been already.
358 .LP
359 The
360 .I st_ctime
361 and
362 .I st_mtime
363 field for a file mapped with
364 .B PROT_WRITE
365 and
366 .B MAP_SHARED
367 will be updated after
368 a write to the mapped region, and before a subsequent
369 .BR msync (2)
370 with the
371 .B MS_SYNC
372 or
373 .B MS_ASYNC
374 flag, if one occurs.
375 .SH RETURN VALUE
376 On success,
377 .BR mmap ()
378 returns a pointer to the mapped area.
379 On error, the value
380 .B MAP_FAILED
381 (that is,
382 .IR "(void\ *)\ \-1" )
383 is returned, and
384 .I errno
385 is set appropriately.
386 On success,
387 .BR munmap ()
388 returns 0, on failure \-1, and
389 .I errno
390 is set (probably to
391 .BR EINVAL ).
392 .SH ERRORS
393 .TP
394 .B EACCES
395 A file descriptor refers to a non-regular file.
396 Or a file mapping was requested, but
397 .I fd
398 is not open for reading.
399 Or
400 .B MAP_SHARED
401 was requested and
402 .B PROT_WRITE
403 is set, but
404 .I fd
405 is not open in read/write
406 .RB ( O_RDWR )
407 mode.
408 Or
409 .B PROT_WRITE
410 is set, but the file is append-only.
411 .TP
412 .B EAGAIN
413 The file has been locked, or too much memory has been locked (see
414 .BR setrlimit (2)).
415 .TP
416 .B EBADF
417 .I fd
418 is not a valid file descriptor (and
419 .B MAP_ANONYMOUS
420 was not set).
421 .TP
422 .B EINVAL
423 We don't like
424 .IR addr ,
425 .IR length ,
426 or
427 .I offset
428 (e.g., they are too large, or not aligned on a page boundary).
429 .TP
430 .B EINVAL
431 (since Linux 2.6.12)
432 .I length
433 was 0.
434 .TP
435 .B EINVAL
436 .I flags
437 contained neither
438 .B MAP_PRIVATE
439 or
440 .BR MAP_SHARED ,
441 or contained both of these values.
442 .TP
443 .B ENFILE
444 .\" This is for shared anonymous segments
445 .\" [2.6.7] shmem_zero_setup()-->shmem_file_setup()-->get_empty_filp()
446 The system limit on the total number of open files has been reached.
447 .\" .TP
448 .\" .B ENOEXEC
449 .\" A file could not be mapped for reading.
450 .TP
451 .B ENODEV
452 The underlying filesystem of the specified file does not support
453 memory mapping.
454 .TP
455 .B ENOMEM
456 No memory is available, or the process's maximum number of mappings would
457 have been exceeded.
458 .TP
459 .B EPERM
460 The
461 .I prot
462 argument asks for
463 .B PROT_EXEC
464 but the mapped area belongs to a file on a filesystem that
465 was mounted no-exec.
466 .\" (Since 2.4.25 / 2.6.0.)
467 .TP
468 .B EPERM
469 The operation was prevented by a file seal; see
470 .BR fcntl (2).
471 .TP
472 .B ETXTBSY
473 .B MAP_DENYWRITE
474 was set but the object specified by
475 .I fd
476 is open for writing.
477 .TP
478 .B EOVERFLOW
479 On 32-bit architecture together with the large file extension
480 (i.e., using 64-bit
481 .IR off_t ):
482 the number of pages used for
483 .I length
484 plus number of pages used for
485 .I offset
486 would overflow
487 .I "unsigned long"
488 (32 bits).
489 .LP
490 Use of a mapped region can result in these signals:
491 .TP
492 .B SIGSEGV
493 Attempted write into a region mapped as read-only.
494 .TP
495 .B SIGBUS
496 Attempted access to a portion of the buffer that does not correspond
497 to the file (for example, beyond the end of the file, including the
498 case where another process has truncated the file).
499 .SH CONFORMING TO
500 SVr4, 4.4BSD, POSIX.1-2001.
501 .\" SVr4 documents additional error codes ENXIO and ENODEV.
502 .\" SUSv2 documents additional error codes EMFILE and EOVERFLOW.
503 .SH AVAILABILITY
504 On POSIX systems on which
505 .BR mmap (),
506 .BR msync (2),
507 and
508 .BR munmap ()
509 are available,
510 .B _POSIX_MAPPED_FILES
511 is defined in \fI<unistd.h>\fP to a value greater than 0.
512 (See also
513 .BR sysconf (3).)
514 .\" POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
515 .\" -1: unavailable, 0: ask using sysconf().
516 .\" glibc defines it to 1.
517 .SH NOTES
518 On some hardware architectures (e.g., i386),
519 .B PROT_WRITE
520 implies
521 .BR PROT_READ .
522 It is architecture dependent whether
523 .B PROT_READ
524 implies
525 .B PROT_EXEC
526 or not.
527 Portable programs should always set
528 .B PROT_EXEC
529 if they intend to execute code in the new mapping.
530
531 The portable way to create a mapping is to specify
532 .I addr
533 as 0 (NULL), and omit
534 .B MAP_FIXED
535 from
536 .IR flags .
537 In this case, the system chooses the address for the mapping;
538 the address is chosen so as not to conflict with any existing mapping,
539 and will not be 0.
540 If the
541 .B MAP_FIXED
542 flag is specified, and
543 .I addr
544 is 0 (NULL), then the mapped address will be 0 (NULL).
545
546 Certain
547 .I flags
548 constants are defined only if either
549 .BR _BSD_SOURCE
550 or
551 .BR _SVID_SOURCE
552 is defined.
553 (Requiring
554 .BR _GNU_SOURCE
555 also suffices,
556 and requiring that macro specifically would have been more logical,
557 since these flags are all Linux-specific.)
558 The relevant flags are:
559 .BR MAP_32BIT ,
560 .BR MAP_ANONYMOUS
561 (and the synonym
562 .BR MAP_ANON ),
563 .BR MAP_DENYWRITE ,
564 .BR MAP_EXECUTABLE ,
565 .BR MAP_FILE ,
566 .BR MAP_GROWSDOWN ,
567 .BR MAP_HUGETLB ,
568 .BR MAP_LOCKED ,
569 .BR MAP_NONBLOCK ,
570 .BR MAP_NORESERVE ,
571 .BR MAP_POPULATE ,
572 and
573 .BR MAP_STACK .
574 .\"
575 .SS C library/kernel ABI differences
576 This page describes the interface provided by the glibc
577 .BR mmap ()
578 wrapper function.
579 Originally, this function invoked a system call of the same name.
580 Since kernel 2.4, that system call has been superseded by
581 .BR mmap2 (2),
582 and nowadays
583 .\" Since around glibc 2.1/2.2, depending on the platform.
584 the glibc
585 .BR mmap ()
586 wrapper function invokes
587 .BR mmap2 (2)
588 with a suitably adjusted value for
589 .IR offset .
590 .SH BUGS
591 On Linux there are no guarantees like those suggested above under
592 .BR MAP_NORESERVE .
593 By default, any process can be killed
594 at any moment when the system runs out of memory.
595
596 In kernels before 2.6.7, the
597 .B MAP_POPULATE
598 flag has effect only if
599 .I prot
600 is specified as
601 .BR PROT_NONE .
602
603 SUSv3 specifies that
604 .BR mmap ()
605 should fail if
606 .I length
607 is 0.
608 However, in kernels before 2.6.12,
609 .BR mmap ()
610 succeeded in this case: no mapping was created and the call returned
611 .IR addr .
612 Since kernel 2.6.12,
613 .BR mmap ()
614 fails with the error
615 .B EINVAL
616 for this case.
617
618 POSIX specifies that the system shall always
619 zero fill any partial page at the end
620 of the object and that system will never write any modification of the
621 object beyond its end.
622 On Linux, when you write data to such partial page after the end
623 of the object, the data stays in the page cache even after the file
624 is closed and unmapped
625 and even though the data is never written to the file itself,
626 subsequent mappings may see the modified content.
627 In some cases, this could be fixed by calling
628 .BR msync (2)
629 before the unmap takes place;
630 however, this doesn't work on tmpfs
631 (for example, when using POSIX shared memory interface documented in
632 .BR shm_overview (7)).
633 .SH EXAMPLE
634 .\" FIXME . Add an example here that uses an anonymous shared region for
635 .\" IPC between parent and child.
636 .PP
637 The following program prints part of the file specified in
638 its first command-line argument to standard output.
639 The range of bytes to be printed is specified via offset and length
640 values in the second and third command-line arguments.
641 The program creates a memory mapping of the required
642 pages of the file and then uses
643 .BR write (2)
644 to output the desired bytes.
645 .SS Program source
646 .nf
647 #include <sys/mman.h>
648 #include <sys/stat.h>
649 #include <fcntl.h>
650 #include <stdio.h>
651 #include <stdlib.h>
652 #include <unistd.h>
653
654 #define handle_error(msg) \\
655     do { perror(msg); exit(EXIT_FAILURE); } while (0)
656
657 int
658 main(int argc, char *argv[])
659 {
660     char *addr;
661     int fd;
662     struct stat sb;
663     off_t offset, pa_offset;
664     size_t length;
665     ssize_t s;
666
667     if (argc < 3 || argc > 4) {
668         fprintf(stderr, "%s file offset [length]\\n", argv[0]);
669         exit(EXIT_FAILURE);
670     }
671
672     fd = open(argv[1], O_RDONLY);
673     if (fd == \-1)
674         handle_error("open");
675
676     if (fstat(fd, &sb) == \-1)           /* To obtain file size */
677         handle_error("fstat");
678
679     offset = atoi(argv[2]);
680     pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) \- 1);
681         /* offset for mmap() must be page aligned */
682
683     if (offset >= sb.st_size) {
684         fprintf(stderr, "offset is past end of file\\n");
685         exit(EXIT_FAILURE);
686     }
687
688     if (argc == 4) {
689         length = atoi(argv[3]);
690         if (offset + length > sb.st_size)
691             length = sb.st_size \- offset;
692                 /* Can\(aqt display bytes past end of file */
693
694     } else {    /* No length arg ==> display to end of file */
695         length = sb.st_size \- offset;
696     }
697
698     addr = mmap(NULL, length + offset \- pa_offset, PROT_READ,
699                 MAP_PRIVATE, fd, pa_offset);
700     if (addr == MAP_FAILED)
701         handle_error("mmap");
702
703     s = write(STDOUT_FILENO, addr + offset \- pa_offset, length);
704     if (s != length) {
705         if (s == \-1)
706             handle_error("write");
707
708         fprintf(stderr, "partial write");
709         exit(EXIT_FAILURE);
710     }
711
712     exit(EXIT_SUCCESS);
713 }
714 .fi
715 .SH SEE ALSO
716 .BR getpagesize (2),
717 .BR memfd_create (2),
718 .BR mincore (2),
719 .BR mlock (2),
720 .BR mmap2 (2),
721 .BR mprotect (2),
722 .BR mremap (2),
723 .BR msync (2),
724 .BR remap_file_pages (2),
725 .BR setrlimit (2),
726 .BR shmat (2),
727 .BR shm_open (3),
728 .BR shm_overview (7)
729
730 The descriptions of the following files in
731 .BR proc (5):
732 .IR /proc/[pid]/maps ,
733 .IR /proc/[pid]/map_files ,
734 and
735 .IR /proc/[pid]/smaps .
736
737 B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391.
738 .\"
739 .\" Repeat after me: private read-only mappings are 100% equivalent to
740 .\" shared read-only mappings. No ifs, buts, or maybes. -- Linus
741 .SH COLOPHON
742 This page is part of release 3.79 of the Linux
743 .I man-pages
744 project.
745 A description of the project,
746 information about reporting bugs,
747 and the latest version of this page,
748 can be found at
749 \%http://www.kernel.org/doc/man\-pages/.