◄Up► ◄Next► ◄Previous► ──────────────────────────────────────────────────────────────────────────── include vmm.inc VMMcall _Allocate_Temp_V86_Data_Area, <nBytes, flags> or eax, eax ; zero if error jz error mov [Address], eax ; address of temporary block The _Allocate_Temp_V86_Data_Area service allocates a block of memory from the global V86 data area. The block is for exclusive use by the virtual device during system initialization only. A virtual device typically allocates a temporary block to serve as a buffer for calls to MS-DOS or BIOS functions. A virtual device makes such calls using the Simulate_Int service. This service is only available during initialization. Parameter Description ──────────────────────────────────────────────────────────────────────────── nBytes Specifies the number of bytes to allocate. flags Specifies the operation flags. This parameter must be set to 0. Return Value The EAX register contains the ring-0 linear address of the block if the service is successful. Otherwise, EAX contains zero to indicate an error such as insufficient memory to satisfy the request or temporary area already allocated. Comments This service always aligns the temporary block on a paragraph boundary and fills the block with zeros. Virtual devices must free the temporary block as soon as possible. The system provides only one temporary data area, therefore only one temporary block can be allocated at a time. Attempts to allocate a temporary block when it is already allocated will result in an error. Uses EAX See Also _Free_Temp_V86_Data_Area ♦