INT 31H 0c00H: Setup DPMI TSR Callback

                                                    Compatibility: DPMI 1.0+ 
 Expects: AX    0c00H
          ES:DI (or ES:EDI) address of 40-byte buffer (see below)
 Returns: CF    NC (clear) if successful; else AX = DPMI Error Code
    Info: This sets up for a DPMI client to provide memory-resident
          protected-mode services to other protected-mode clients.

          After using this fn and INT 31H 0c00H, you will be notified
          whenever another DPMI program in the same VM is loaded or

 DS:(E)DI this points to a structure formatted as follows:

            Offset Size Contents
            ▀▀▀▀▀▀ ▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
             +0      8  lDesc16Data  descriptor for 16-bit data segment
             +8      8  lDesc16Code  descriptor for 16-bit code segment
            +10H     2  lOff16Proc   offset of 16-bit callback procedure
            +12H     2  res          reserved
            +14H     8  lDesc32Data  descriptor for 32-bit data segment
            +1cH     8  lDesc32Code  descriptor for 32-bit code segment
            +24H     4  lOff32Proc   offset of 32-bit callback procedure
                    40               size of this structure

          You may use INT 31H 000bH (query descriptor) to obtain info to
          fill some of the above fields.  If you will support only 16-bit
          or only 32-bit applications, put zeros in the structure members
          you don't need.

   Notes: ■ If you only need to provide services to real-mode applications
            in the current VM, then you should use INT 31H 0300H to use DOS
            services to intercept interrupt vectors and make yourself RAM-

          ■ After calling this fn, use INT 31H 02xxH services to intercept
            interrupts and use INT 31H 0c01H to make your code RAM-

            When a DPMI client gets loaded, your callback address will be
            called via a FAR CALL with AX=0 when a program is loading or
            AX=1 when a program is terminating.  On program loads, you will
            typically intercept one or more interrupts to supply services
            in the current VM.

See Also: DPMI API
          INT 2fH: Multiplex Interrupt
          DOS Functions