Re: MmMapIoSpace in OAL
From: Helge Kruse (Helge.Kruse-nospam_at_gmx.net)
Date: 05/18/04
- Previous message: Deepak Bhople: "ContrastControl in PPC"
- In reply to: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Next in thread: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Reply: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 18 May 2004 22:57:02 +0200
Hi Dave, thanks for response.
The big picture:
I have a WinCE 3.0 x86 platform. I have a processor with memory mapped
devices connected to one, two or three chip selects. Each chip select is
mapped to an physical address range.
The devices available today occupy up to 128 MBytes. I must synchronize the
chip access per chip select, but I want to allow different threads to access
different devices. That's why I need a mapping from virtual addresses to
phyiscal addresses.
One solution seems to be VirtualAlloc/VirtualCopy. But the allocates the
range in the address space of the running process. The 32 MByte per process
limit inhibits this approach.
Another solution is to modify the function OEMInitPageTable in OEMINIT.ASM.
I can add entries to PageTable. This costs a lot of assembler code lines.
Many "PageRange"s must be defined. This can be done with macros, but also
increases the WinCE image's footprint. This is important in the case, that
smaller flash devices are used in the target system.
- I would have wasted address space.
- The page table entries (not page table directory entries) occupies
hundreds of kilobytes flash, that is never used.
What is the best way to handle access to devices with large address space?
Is there a way to build the memory blocks containing the PageRanges
dynmically?
I could construct the contents of such memory blocks. But how do I get the
buffer __before__ activating page, ie. in OEMInit?
In my current experiments I defined the PageRange in OEMInitPageTable.
I need to setup the devices during system startup in the OAL before the
registry is available. I need to be called from the system. Currently I
check in every OEMIoControl, if the system has been initialize and call my
initialization function. This is a bit awkward.
Is there an OEMIoControl garanteed to be called at first and only once? Is
there another way to be get called when paging is enabled?
Kind Regards, Helge
- Previous message: Deepak Bhople: "ContrastControl in PPC"
- In reply to: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Next in thread: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Reply: Steve Maillet \(eMVP\): "Re: MmMapIoSpace in OAL"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|