File: remap_file_pages.2

package info (click to toggle)
manpages-ja 0.5.0.0.20080615-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 20,508 kB
  • ctags: 1
  • sloc: sh: 13,690; perl: 157; makefile: 114
file content (152 lines) | stat: -rw-r--r-- 4,326 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
.\" Copyright (C) 2003, Michael Kerrisk (mtk.manpages@gmail.com)
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one.
.\"
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.
.\"
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"
.\" 2003-12-10 Initial creation, Michael Kerrisk <mtk.manpages@gmail.com>
.\" 2004-10-28 aeb, corrected prototype, prot must be 0
.\"
.\" Japanese Version Copyright (c) 2004-2005 Yuichi SATO
.\"         all rights reserved.
.\" Translated Thu Jun 24 06:00:37 JST 2004
.\"         by Yuichi SATO <ysato444@yahoo.co.jp>
.\" Updated & Modified Mon Jan  3 02:50:11 JST 2005 by Yuichi SATO
.\" Updated & Modified Mon Oct 10 01:15:38 JST 2005
.\"         by Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
.\"
.TH REMAP_FILE_PAGES 2 2004-10-28 "Linux" "Linux Programmer's Manual"
.SH ̾
remap_file_pages \- եޥåԥ󥰤롣
.SH 
.nf
.B #define _GNU_SOURCE
.B #include <sys/mman.h>
.sp
.BI "int remap_file_pages(void *" start ", size_t " size ", int " prot ,
.BI "                     ssize_t " pgoff ", int " flags );
.fi
.SH 
.BR remap_file_pages ()
ƥॳʥޥåԥ󥰡
ĤޤեΥڡϢ³ʤ֤ǥޥåפ
ޥåԥ󥰤뤿˻Ȥ롣
.BR remap_file_pages ()
Ȥ
.BR mmap (2)
򷫤֤ƻȤͥƤϡ
ԤˡǤϥͥ뤬 VMA (Virtual Memory Area, ۥΰ)
ǡ¤ΤɲäǺɬפʤȤǤ롣

ޥåԥ󥰤뤿ˤϡ
ʲΤ褦ʥƥåפ¹Ԥ:
.TP 3
1.
.BR mmap (2)
Ȥޥåԥ󥰤 (Υޥåԥ󥰤ϺǽǤ)
Υޥåԥ󥰤
.B MAP_SHARED
ե饰ꤷƺʤФʤʤ
.TP
2.
.BR remap_file_pages ()
 1 ʾƤӽФơ
ޥåԥ󥰤ΥڡȥեΥڡбطƹ롣
եƱڡޥåԥΰʣξ
ޥåפ뤳ȤǽǤ롣
.LP
.I pgoff

.I size
ϡޥåԥǺ֤եΰꤹ롣
.I pgoff
ϥե륪եåȤǤꡢñ̤ϥƥΥڡǤ롣
.I size
ΰĹǤꡢñ̤ϥХȤǤ롣

.I start
 2 ĤŪǻȤ롣
 1 Ūϡΰˤäƺڡ
ޥåԥ󥰤̤뤳ȤǤ롣
ä
.I start

.BR mmap (2)
θƤӽФDz˥ޥåפ줿ΰΥɥ쥹ǤʤФʤʤ
 2 Ūϡ
.I pgoff

.I size
Ǽ̤եڡ֤ͽΥɥ쥹
.I start
ˤäƻꤹ뤳ȤǤ롣

.I start

.I size
˻ꤹͤϡƥΥڡܿȤ٤Ǥ롣
ʳξ硢ͥϡξפͤ
Ǥᤤڡܿءڤ겼ס
.\" δݤѤǡmunmap()/mprotect()  mlock() 
.\" ƱͤΰνˡȤ̷⤹롣
.\" MTK, 14 Sep 2005

.I prot
 0 ˻ꤵʤФʤʤ

.I flags

.BR mmap (2)
ΤΤƱ̣Ǥ뤬
.B MAP_NONBLOCK
ʳƤΥե饰̵뤵롣
.SH ֤
.BR remap_file_pages ()
 0 ֤
顼ξ硢\-1 ֤졢
.I errno
Ŭڤꤵ롣
.SH 顼
.TP
.B EINVAL
.I start

.B MAP_SHARED
ե饰ꤷƺ줿ͭʥޥåԥ󥰤򻲾ȤƤʤ
.TP
.B EINVAL
.IR start ,
.IR size ,
.IR prot ,
.I pgoff
Τ줫Ǥ롣
.\" ޤ vma->vm_ops->populate() ¾Υ顼⤷ʤ
.SH С
.BR remap_file_pages ()
ƥॳ Linux 2.5.46 о줷
glibc ǤΥݡȤ glibc С 2.3.3 ɲä줿
.SH 
.BR remap_file_pages ()
ƥॳ Linux ͭΤΤǤ롣
.SH Ϣ
.BR getpagesize (2),
.BR mmap (2),
.BR mmap2 (2),
.BR mprotect (2),
.BR mremap (2),
.BR msync (2),
.BR feature_test_macros (7)