Maps a physical memory area, defined by its absolute physical address and contiguous length before any translation imposed by the paging system, into the current process' virtual address space.
PVOID MapRtPhysicalMemory( DWORD dwAbsoluteAddress, // absolute physical address of memory to be mapped DWORD cbSize // size of area to be mapped );
dwAbsoluteAddress
cbSize
MapRtPhysicalMemory maps physical memory starting at dwAbsoluteAddress
for size bytes into the virtual address space of this calling thread's process.
If the values of dwAbsoluteAddress
and cbSize
are not 4Kbyte-aligned, then the kernel will make adjustments so that the mapping is aligned. Thus the virtual memory consumed will be more than the value of cbSize.
Use FreeRtMemory to delete the mapping created by this call and to free the virtual memory associated with it.
This call is limited to mapping memory from below 4 GiB. Use MapRtPhysicalMemory64 to map physical memory from any physical address.
The address of the area mapped.
NULL
E_OK 0x0000
E_MEM 0x0002
E_VMEM 0x00F0
E_PARAM 0x8004
cbSize
is zero. Versions | Defined in | Include | Link to |
---|---|---|---|
INtime 3.0 | intime/rt/include/rtbase.h | rt.h | rt.lib |