DOSMGR_Alloc_Local_Sys_VM_Mem

include dosmgr.inc

mov ax, NumParagraphs
VxDcall DOSMGR_Alloc_Local_Sys_VM_Mem
 

Reserves local V86 memory in the system VM. Uses EAX and Flags.

The offset returned is an offset from First V86 Page which is returned by the service GetFirstV86Page. This page is not valid until the start of the Sys_VM_Init System_Control broadcast. So, a client of this service must watch for that control call, then call GetFirstV86Page and add the offset returned by this service to determine the actual location of the reserved memory. The memory is actually not ready until the SHELL VxD calls DOSMGR to do the initial exec, so the memory is only available after the SHELL VxD's Sys_VM_Init handler. Also note that this service is an initialization time only service, so it must be called before the end of the Init_Complete control call.