delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/10/03/11:15:41

Date: Sun, 3 Oct 1999 13:05:18 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Alex Mendes da Costa <alexmdc AT virtualis DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: Locking Memory
In-Reply-To: <37F59194.8E0E36A6@virtualis.com>
Message-ID: <Pine.SUN.3.91.991003130440.16939E-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sat, 2 Oct 1999, Alex Mendes da Costa wrote:

> 2. Now I don't understand this bit. It says call
> __dpmi_lock_linear_region a series of times. But how do I know what
> region I have to lock?

I already answered this one in another thread where you asked about
it.

> 3. Then call __dpmi_set_protected_mode_interrupt_vector with _my_cs()
> and my function offset. How do I get my function offset?

The offset of a function is just its address cast to an unsigned
long.  Here's how to compute an offset of a hypothetical function
my_func:

    unsigned long func_offset = (unsigned long)my_func;

The offset of a variable is its address cast to an unsigned long:

    unsigned long var_offset = (unsigned long)&my_var;

- Raw text -


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