blob: bce222b69411c3ffb49cc751ee2224b2eb6f507c (
plain)
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
|
<table class="head">
<tr>
<td class="head-ltitle">VM_MAP_CHECK_PROTECTION(9)</td>
<td class="head-vol">Kernel Developer's Manual</td>
<td class="head-rtitle">VM_MAP_CHECK_PROTECTION(9)</td>
</tr>
</table>
<div class="manual-text">
<section class="Sh">
<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1>
<p class="Pp"><code class="Nm">vm_map_check_protection</code> —
<span class="Nd">check memory protection for a vm_map</span></p>
</section>
<section class="Sh">
<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1>
<p class="Pp"><code class="In">#include
<<a class="In">sys/param.h</a>></code>
<br/>
<code class="In">#include <<a class="In">vm/vm.h</a>></code>
<br/>
<code class="In">#include <<a class="In">vm/vm_map.h</a>></code></p>
<p class="Pp"><var class="Ft">boolean_t</var>
<br/>
<code class="Fn">vm_map_check_protection</code>(<var class="Fa">vm_map_t
map</var>, <var class="Fa">vm_offset_t start</var>,
<var class="Fa">vm_offset_t end</var>, <var class="Fa">vm_prot_t
protection</var>);</p>
</section>
<section class="Sh">
<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1>
<p class="Pp">The
<a class="permalink" href="#vm_map_check_protection"><code class="Fn" id="vm_map_check_protection">vm_map_check_protection</code></a>()
function asserts that the target <var class="Fa">map</var> allows the
specified privilege <var class="Fa">protection</var> over the entire address
range from <var class="Fa">start</var> to <var class="Fa">end</var>. The
region MUST be contiguous; no holes are allowed.</p>
</section>
<section class="Sh">
<h1 class="Sh" id="IMPLEMENTATION_NOTES"><a class="permalink" href="#IMPLEMENTATION_NOTES">IMPLEMENTATION
NOTES</a></h1>
<p class="Pp">This code does not and SHOULD not check whether the contents of
the region are accessible. For example, a small file may be mapped into an
address space which is significantly larger in size.</p>
</section>
<section class="Sh">
<h1 class="Sh" id="RETURN_VALUES"><a class="permalink" href="#RETURN_VALUES">RETURN
VALUES</a></h1>
<p class="Pp">The <code class="Fn">vm_map_check_protection</code>() function
returns TRUE if the privilege is allowed; if it is not allowed, or if any
other error occurred, the value FALSE is returned.</p>
</section>
<section class="Sh">
<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
ALSO</a></h1>
<p class="Pp"><a class="Xr">munmap(2)</a>, <a class="Xr">vm_map(9)</a>,
<a class="Xr">vm_map_protect(9)</a></p>
</section>
<section class="Sh">
<h1 class="Sh" id="AUTHORS"><a class="permalink" href="#AUTHORS">AUTHORS</a></h1>
<p class="Pp">This manual page was written by <span class="An">Bruce M
Simpson</span>
<<a class="Mt" href="mailto:bms@spc.org">bms@spc.org</a>>.</p>
</section>
</div>
<table class="foot">
<tr>
<td class="foot-date">July 19, 2003</td>
<td class="foot-os">FreeBSD 15.0</td>
</tr>
</table>
|