- 7.2.26. -
Table of Contents
7. PMODE/W MSDOS Extender
7.2. PMODE/W Supported DPMI INT 31h functions
7.2.26. Function 0305 - Get State Save/Restore Addresses
7.2.26. Function 0305 - Get State Save/Restore
Addresses
PMODE/W API
This function Returns the address of two procedures used to save and restore
the state of the current task's registers in the mode (protected or real)
which is not currently executing.
In:
AX = 0305h
Out:
always successful:
carry flag clear
AX = size of buffer in bytes required to save state
BX:CX = segment:offset of real mode routine used
to save/restore state
SI:EDI = selector:offset of protected mode routine
used to save/restore state
Notes:
The real mode segment:offset returned by this function should be called only
in real mode to save/restore the state of the protected mode register.
The protected mode selector:offset returned by this function should be called
only in protected mode to save/restore the state of the real mode registers.
Both of the state save/restore procedures are entered by a FAR CALL with the
following parameters:
AL = 0 to save state
= 1 to restore state
ES:(E)DI = (selector or segment):offset of state buffer
The state buffer must be at least as large as the value returned in AX
by INT 31h function 0305h. The state save/restore procedures do not modify
an registers. DI must be used for the buffer offset in real mode, EDI must
be used in protected mode.
Some DPMI hosts and VCPI/XMS/raw will not require the state to be saved,
indicating this by returning a buffer size of zero in AX. In such cases,
that addresses returned by this function can still be called, although the
will simply return without performing any useful function.
Clients do not need to call the state save/restore procedures before using
INT 31h function 0300h, 0301h, or 0302h. The state save/restore procedures
are provided for clients that use the raw mode switch services only.
- 7.2.26. -