Reference

This section is an alphabetical list of the real-mode initialization services.

LDRSRV_COPY_EXTENDED_MEMORY

mov   ax, 0006h             ; Copy_Extended_Memory
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Allocates a block of extended memory in the specified data group (init, locked, or pageable) to the size requested and initializes the block with the given data.

AX
Must be 0006h.
CX
Number of bytes to allocate. Actual size is rounded up to the nearest DWORD.
DX
Type of data being allocated. Can be one of these values.
LDRSRV_COPY_INIT INIT data
LDRSRV_COPY_LOCKED LOCKED data
LDRSRV_COPY_PAGEABLE PAGEABLE data

DS:SI
Address of data to be copied.

This service provides a way for VxDs to pass data to their protected-mode portions. The VxD creates a block of extended memory and passes its linear address through the VxD reference DWORD (that is, the value of EDX on exit from real-mode initialization). Multiple blocks allocated by a single VxD are guaranteed to be contiguous in linear address space, but not necessarily in physical address space. PAGEABLE data may actually be allocated as LOCKED data, at the loader's discretion. Initialization (INIT) data is always locked, and is discarded after all VxD initialization phases are completed.

LDRSRV_GET_MEMORY_INFO

mov   ax, 0007h                  ; Get_Memory_Info
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Retrieves information about computer memory.

LDRSRV_GET_NEXT_PROFILE_STRING

mov    ax, 0001h         ; Get_Next_Profile_String
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Retrieves the address of a null-terminated string representing the next value for a specified setting in the SYSTEM.INI file. This service is used by virtual devices that have multiple entries with the same setting name. Uses EAX, EDX, ES, Flags.

AX
Must be 0001h.
DS:DI
Points to a null-terminated string specifying the name of the setting to search for.
ES:DX
Contains an address that was previously retrieved using the Get_Profile_String or Get_Next_Profile_String service.

LDRSRV_GET_PROFILE_BOOLEAN

mov    ax, 0003h         ; Get_Profile_Boolean
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Returns a Boolean value from the SYSTEM.INI file. Uses ECX, Flags.

Setting Value
0 0h
1 0FFFFFFFFh
False 0h
No 0h
Off 0h
On 0FFFFFFFFh
True 0FFFFFFFFh
Yes 0FFFFFFFFh

If both the carry and zero flags are set, the setting has no current value and ECX contains the default value. If just the carry flag is set, the specified setting cannot be found.

AX
Must be 0003h.
ECX
Specifies the default value if the setting has no current value. The default value must be either 0FFFFFFFFh or 0h.
DS:SI
Points to a null-terminated string specifying the name of the section to search. If the SI register is zero, the service searches the [386Enh] section.
DS:DI
Points to a null-terminated string specifying the name of the setting to search for.

LDRSRV_GET_PROFILE_DECIMAL_INT

mov    ax, 0004h         ; Get_Profile_Decimal_Int
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Returns a decimal integer value from the SYSTEM.INI file. Uses ECX, Flags.

AX
Must be 0004h.
ECX
Specifies the default value if the setting has no current value.
DS:SI
Points to a null-terminated string specifying the name of the section to search. If the SI register is zero, the service searches the [386Enh] section.
DS:DI
Points to a null-terminated string specifying the name of the setting to search for.

LDRSRV_GET_PROFILE_HEX_INT

mov    ax, 0005h         ; Get_Profile_Hex_Int
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure
 

Returns a hexadecimal integer value from the SYSTEM.INI file. Uses ECX, Flags.

AX
Must be 0005h.
ECX
Specifies the default value if the setting has no current value.
DS:SI
Points to a null-terminated string specifying the name of the section to search. If the SI register is zero, the service searches the [386Enh] section.
DS:DI
Points to a null-terminated string specifying the name of the setting to search for.

LDRSRV_GET_PROFILE_STRING

mov    ax, 0000h         ; Get_Profile_String
call  dword ptr [_ServiceEntry]  ; service entry point passed to
                                 ; real-mode initialization procedure

Searches the SYSTEM.INI file for the specified entry, and returns a pointer to a string. Uses EAX, EDX, ES, Flags.

AX
Must be 0000h.
DS:SI
Points to a null-terminated string specifying the name of the section to search. If the SI register is zero, the service searches the [386Enh] section of the SYSTEM.INI file.
DS:DI
Points to a null-terminated string specifying the name of the setting to search for.
ES:DX
Points to null-terminated string specifying the default value if the requested setting is not found.

The real-mode initialization procedure must not modify the returned string. The address returned points to the initialization file data area and is read only.