Message-Id: <200001080301.VAA05490@lakdiva.slt.lk> From: "Kalum Somaratna aka Grendel" To: djgpp AT delorie DOT com Date: Fri, 7 Jan 2000 21:01:51 +0600 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Subject: Re: real-mode functions In-reply-to: X-mailer: Pegasus Mail for Win32 (v3.12) Reply-To: djgpp AT delorie DOT com Errors-To: dj-admin AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On 7 Jan 00, at 7:20, sl wrote: > Hi, > > DJGPP provides a couple of functions to handle calling of real-mode > functions, unfortunately I am somehow suppose to know if the real-mode > function terminates with a 'iret' or something else. All I know is > that this is a function somewhere in memory with a 'far ptr' to it.. > How am I suppose to know which functions to pick? > If you real mode procedure is an interrupt handling routine then it will terminate with iret and you should use the _go32_dpmi_simulate_fcall_iret function. But AFAIK realmode functions which are not interrupt handler's, like for example calling a function resident in a dos driver and asking it to fill some memory with data, the _go32_dpmi_simulate_fcall function can be used. So in your case since you mention that the function has a far ptr to it the _go32_dpmi_simulate_fcall should do the trick. I use it to call functions in the CDROM device driver like getting the device info etc. Hope This Helps, Kalum