delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/02/05/06:53:17

From: fabian AT cs DOT uct DOT ac DOT za (Fabian Nunez)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Executing Privileged Instructions from Ring 3
Date: 4 Feb 1999 07:03:27 GMT
Organization: Adamastor
Lines: 32
Message-ID: <79bgo0$l3i$1@news.adamastor.ac.za>
References: <79as03$cda$1 AT nnrp1 DOT dejanews DOT com>
NNTP-Posting-Host: aji.cs.uct.ac.za
X-Newsreader: NN version 6.5.0 #1 (NOV)
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

In <79as03$cda$1 AT nnrp1 DOT dejanews DOT com> russell DOT thamm AT dsto DOT defence DOT gov DOT au writes:

>I have a program that needs to run at ring0 (cwsdpr0) because
>it executes one privileged instruction:

>movl  %cr3,%eax

>Is there any simple way that I can get the Page Table address
>from Ring3?

>I am doing an address translation to find a physical address
>for DMA. I know I should be using VDS but the FAQ tells me
>that CWSDPMI doesn't support it.

>thanks
>Russell Thamm

>-----------== Posted via Deja News, The Discussion Network ==----------
>http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own    

Well, you don't need to!  DJGPP's startup code identity-maps all
memory below the 1MB mark, so you just need to allocate DOS memory and
use it (the FAQ describes how to do this).  It's all done with dpmi
0.9 calls, so pretty much any dpmi server will work.

Hope that helps
Fabian
--
Fabian Nunez, MSc student     Collaborative Visual Computing Laboratory,
fabian AT cs DOT uct DOT ac DOT za           University of Cape Town

"Ram Disk" is NOT an installation procedure!

- Raw text -


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