;************************************************ ;*** *** ;*** XmsDefs.ASM *** ;*** *** ;*** Contains definitions for XMS routines *** ;*** *** ;************************************************ ; ; Define the extended function interrupt which gives us the ; XMS handler address: ; XFunc equ 2fh ; ; Define the function code for XMS, and the two sub-codes: ; XFuncXMS equ 43h XFuncXMSPres equ 0h XFuncXMSEntry equ 10h ; ; Define the XMSPresent response: ; XMSPresent equ 80h ; ; Now define the 2.0 XMS function codes. ; These are 8 bit values which are loaded into ; AH before calling the XMS handler (the address of which ; was determined using XFuncXMSEntry int). ; XMSGetVersion equ 00h XMSAllocHMA equ 01h XMSFreeHMA equ 02h XMSGlobEnabA20 equ 03h XMSGlobDisabA20 equ 04h XMSLocEnabA20 equ 05h XMSLocDisabA20 equ 06h XMSGetA20State equ 07h XMSGetFreeXM equ 08h XMSAllocXM equ 09h XMSFreeXM equ 0ah XMSMoveXM equ 0bh XMSLockXM equ 0ch XMSUnlockXM equ 0dh XMSGetHandInfo equ 0eh XMSResizeXM equ 0fh XMSAllocUM equ 10h XMSFreeUM equ 11h ; ; Now define the XMS error codes: ; XMSErrOK equ 00h ; No error XMSErrUnimp equ 80h ; Unimplemented function XMSErrVDISK equ 81h ; VDISK device detected XMSErrA20 equ 82h ; A20 error XMSErrNoHMA equ 90h ; HMA does not exist XMSErrHMAInUse equ 91h ; HMA already in use XMSErrHMAMin equ 92h ; HMA space req. < /HMAMIN= parameter XMSErrHMANotAll equ 93h ; HMA not allocated XMSErrA20Enab equ 94h ; A20 still enabled XMSErrNoXMLeft equ 0A0h ; All XM allocated XMSErrNoHandles equ 0A1h ; All handles are allocated XMSErrHandInv equ 0A2h ; Invalid handle XMSErrSHandInv equ 0A3h ; Invalid Source Handle XMSErrSOffInv equ 0A4h ; Invalid Source Offset XMSErrDHandInv equ 0A5h ; Invalid Dest Handle XMSErrDOffInv equ 0A6h ; Invalid Dest Offset XMSErrLenInv equ 0A7h ; Invalid Length XMSErrOverlap equ 0A8h ; Invalid move overlap XMSErrParity equ 0A9h ; Parity error XMSErrNoLock equ 0AAh ; Handle not locked XMSErrLock equ 0ABh ; Handle Locked XMSErrLockOvflo equ 0ACh ; Lock count overflo XMSErrLockFail equ 0ADh ; Lock fail XMSErrSmUMB equ 0B0h ; Smaller UMB available XMSErrNoUMB equ 0B1h ; No UMB's available XMSErrUMBInv equ 0B2h ; Invalid UMB segment ; ; Define the Bios interrupt and function codes ; XMSBios equ 15h ; ; Define the two function codes ; XMSBiosXMMove equ 87h ; Move a block of XMS XMSBiosXMSize equ 88h ; Get size of extended memory ; ; Define the access byte ; XMSBiosAccess equ 93h ; The "correct" access byte