Mail Archives: djgpp/2001/08/25/20:35:39
> From: Nick <jp_prongs AT yahoo DOT com>
> Newsgroups: comp.os.msdos.djgpp
> Date: Sat, 25 Aug 2001 06:30:42 -0400
>
> Could somebody just tell me: will my way work or not? If not, why?
It will only work for addresses in the first 1MB, i.e. in the
conventional memory. But for using DMA in the conventional memory,
you don't need this trick at all, since conventional memory is always
mapped 1:1 (i.e. physical and linear addresses are identical). That's
why the FAQ suggests doing DMA with conventional memory: it's easy.
The reason why it won't work above 1MB is that the mapping between the
physical and linear addresses cannot be computed without accessing the
page tables. Page tables are data structures which define the mapping
between physical and linear addresses, and their access is a tricky
business. For ring-0 DPMI servers, somebody posted here code to do
that; similar (but more complicated) code exists for CWSDPMI.
However, for Windows 9X we don't know how to access the page tables.
- Raw text -