www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/02/25/06:10:44

Date: Tue, 25 Feb 1997 13:06:25 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Christoph Kukulies <kuku AT gilberto DOT physik DOT RWTH-Aachen DOT DE>
cc: djgpp AT delorie DOT com
Subject: Re: far pointer - passing to realmode
In-Reply-To: <199702251036.LAA06425@gil.physik.rwth-aachen.de>
Message-ID: <Pine.SUN.3.91.970225130115.7286A-100000@is>
MIME-Version: 1.0

On Tue, 25 Feb 1997, Christoph Kukulies wrote:

> How can I supply these parameters from an address (linear) in my 
> program and convert it into a seg:offset to be used by the
> realmode program?

You can't, period.  Real-mode addresses can only address the first 1MByte
of memory (they are limited to 20 bits), whereas your DJGPP program uses a
4GByte address space (full 32-bit addressing).  These two methods cannot
be reconciled. 

> Would that work at all or would it be better to
> use some low memory area as the transfer buffer where seg:offset
> is know beforehand.

Either use the DJGPP transfer buffer, or allocate your own buffer in 
conventional memory.  The DJGPP FAQ list (available as v2/faq210b.zip 
from the same place you get DJGPP) has the necessary details in sections 
18.2 and 18.4.

- Raw text -


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