Code: Select all
void *AcpiOsMapMemory(ACPI_PHYSICAL_ADDRESS *physical, ACPI_SIZE length);
However I have no idea of where to map those pages. I'm in higher half, and memory from 0xC0000000 to 0xF0000000 is reserved for the kernel executable and Heap. So I thought to map the physical address at 0xF0000000. But if ACPICA calls AcpiOsMapMemory with new datas, before it have Unmapped it through AcpiOsUnmapMemory, it will overwrite the old Page directory, and probably this will cause some problems.
Do I need something like malloc/free for the virtual addresses? Or there is some easier solution to the problem?
Thanks