add directory study
This commit is contained in:
@@ -0,0 +1,86 @@
|
||||
|
||||
|
||||
<h2>Mark Real Mode Region as Pageable
|
||||
<img src="../0.9.gif" alt="[0.9]" width=22 height=17></h2>
|
||||
|
||||
Advises the DPMI host that the specified memory below the 1 MB
|
||||
boundary may be paged to disk.<p>
|
||||
|
||||
<b>Call With</b><br>
|
||||
<img src="r/ax+bx+cx+si+di.gif" alt="" width=245 height=59><br>
|
||||
|
||||
AX = 0602H<br>
|
||||
BX:CX = starting linear address of memory to mark as
|
||||
pageable<br>
|
||||
SI:DI = size of region to be marked (bytes)<p>
|
||||
|
||||
<b>Returns</b><br>
|
||||
<img src="r/ax+c.gif" alt="" width=245 height=59><br>
|
||||
|
||||
<i>if function successful</i><br>
|
||||
Carry flag = clear<p>
|
||||
|
||||
<i>if function unsuccessful</i><br>
|
||||
Carry flag = set<br>
|
||||
AX = <a href="errors.html">error code</a>
|
||||
|
||||
<table border=1 cellspacing=0 cellpadding=4>
|
||||
|
||||
<tr><td>8002H</td><td>invalid state (region already marked as pageable)</td></tr>
|
||||
<tr><td>8025H</td><td>invalid linear address (region is above 1 MB boundary)</td></tr>
|
||||
</table>
|
||||
|
||||
<h2>Notes</h2><ul>
|
||||
|
||||
|
||||
<li>If the function returns an error, none of the memory has been
|
||||
marked as pageable.<p>
|
||||
|
||||
<li>If the specified region overlaps part of a page at the beginning
|
||||
or end of the region, the page(s) will not be marked as pageable.<p>
|
||||
|
||||
<li>Pageability information for a real mode region is maintained as a
|
||||
binary state, not a count. Therefore, multiple calls to this function
|
||||
for the same region have no effect.<p>
|
||||
|
||||
<li>For compatibility with DPMI version 0.9 hosts, a client must call
|
||||
the Relock Real Mode Region function (<a href="310603.html">Int 31H
|
||||
Function 0603H</a>) to relock the memory region before terminating.
|
||||
Memory that remains unlocked after the client has terminated could
|
||||
result in fatal page faults when another program is executed in the
|
||||
same address space. DPMI 1.0 hosts automatically relock real mode
|
||||
memory at client termination.<p>
|
||||
|
||||
<li>Under some DPMI hosts, all conventional memory may be locked by
|
||||
default. If a protected mode program is using memory in the first
|
||||
megabyte of address space, it is recommended that this function be
|
||||
used to turn off automatic page locking for regions of memory that
|
||||
will not be touched at interrupt time.<p>
|
||||
|
||||
<li>The client must not mark memory as pageable in regions that it
|
||||
does not own; i.e. it may only mark as pageable memory that it has
|
||||
previously allocated with <a href="310100.html">Int 31H Function
|
||||
0100H</a> or by a direct call to DOS via the translation functions.
|
||||
For example, marking all free DOS memory as pageable under some DPMI
|
||||
hosts could cause a page fault to occur while inside of DOS, resulting
|
||||
in a crash. Also, a client should not mark the DPMI host data area as
|
||||
pageable.<p>
|
||||
|
||||
<li>Note that address space marked as pageable by this function can
|
||||
still be locked using the Lock Linear Region function (<a
|
||||
href="310600.html">Int 31H Function 0600H</a>). This function is just
|
||||
an advisory service to allow memory that does not need to be locked to
|
||||
be paged out; it disables any automatic locking of real mode memory
|
||||
performed by the DPMI host.<p>
|
||||
|
||||
<li>This function is ignored by DPMI implementations that do not
|
||||
support virtual memory; the function will return the Carry flag clear
|
||||
to indicate success, but has no other effect. DPMI hosts which
|
||||
support virtual memory may also choose to ignore this function, but
|
||||
such hosts must be able to handle page faults transparently at
|
||||
arbitrary points during a client's execution, including within
|
||||
interrupt and exception handlers.<p>
|
||||
|
||||
</ul>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user