Virtual Devices (3.1) (vdag31qh.hlp) (Table of Contents; Topic list)
GetSet_HMA_Info
                                                     Up Next Previous
────────────────────────────────────────────────────────────────────────────
 
include vmm.inc
 
mov     ecx, Action         ; zero to get, nonzero to set
mov     dx, A20Enable       ; A20 enable count (if ecx is nonzero)
VMMcall GetSet_HMA_Info
 
mov     [NoGlobalHMA], eax  ; nonzero if no global HMA user
mov     [XMSCallAddr], ecx  ; loader XMS call address
mov     [A20Enable], edx    ; A20 enable count before Windows started
 
The GetSet_HMA_Info service returns and sets information related to the
high-memory area (HMA) region.
 
This service lets the XMS driver (in the V86MMGR device) determine whether a
global HMA user existed before Windows started and gives the driver access
to the HMA enable count.
 
This service is always valid (not restricted to initialization).
 
Parameter  Description
────────────────────────────────────────────────────────────────────────────
 
Action     Specifies whether to get or set information. If this parameter is
           zero, the service returns HMA information. Otherwise, it sets the
           information.
 
A20Enable  Specifies the A20 enable count to set for the Windows VMM loader.
           The service uses this parameter only if the Action parameter is
           nonzero.
 
Return Value
 
The EAX, ECX, and EX register contain the following HMA information:
 
Register  Description
────────────────────────────────────────────────────────────────────────────
EAX       Specifies whether a global HMA user is present. If this register
          is 0, Windows did not allocate the HMA meaning either there is a
          global HMA user or there is no HMA. If this register is nonzero,
          Windows has allocated the HMA, meaning there is no global HMA
          user.
 
ECX       Specifies the V86-mode address (segment:offset) that Windows used
          to call the XMS driver when loading. The segment address is in the
          high 16 bits of the register.
 
EDX       Specifies the A20 enable count before Windows started.
 
Comments
 
The global HMA flag and loader XMS call address cannot be set.
 
Uses
 
EAX, ECX, EDX, Flags
 
                                      ♦