delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/06/04/13:00:03

Date: Thu, 4 Jun 1998 19:57:45 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: ToolsSmith <ToolsSmith AT usa DOT net>
cc: djgpp AT delorie DOT com
Subject: Re: Newbie application question.
In-Reply-To: <35748C42.7BFAE427@usa.net>
Message-ID: <Pine.SUN.3.91.980604195727.2197G-100000@is>
MIME-Version: 1.0

On Tue, 2 Jun 1998, ToolsSmith wrote:

> We have a large real-mode application compiled in a LARGE memory model
> using Microsoft C 6.0a. From this application we want to make a
> real-mode software interrupt (e.g. INT 10) to a protected mode handler
> resident in extended memory. We are not permitted to modify the existing
> real-mode application in any manner. It is the intent that this
> real-mode application NOT be aware that it is using protected mode
> services located in extended memory. All this in an MS-DOS V6.22
> environment.

Software interrupts aren't reflected to protected mode.  So you will
need to have the protected-mode program install a real-mode callback
for that software interrupt.  Read section 18.9 of the DJGPP FAQ list
(v2/faq210b.zip from the same place you get DJGPP), and then look up
the function _go32_dpmi_allocate_real_mode_callback_iret in the
library docs.

> So, using the DJGPP tools the following questions arise:
>  - What DPMI services are required?

You need to allocate a callback, and then install it as the real-mode
interrupt handler.

>  - Are any other services (e.g. himem.sys, emm386) required?

I don't think these are necessary.  CWSDPMI can run without any of
them, so you shouldn't need them.

>  - What DPMI functions would a client need to use to install itself
>    in extended memory as an interrupt handler callable from real-mode?

I you need the PM program be a TSR, check out the example TSR code in
v2tk directory.

>  - What would be needed to install multiple handers?

I don't understand this.  Do you mean to have them on some chain,
whereby each handler calls the previous one?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019