I have used the real mode INT 15h service 0xE820 and it returned a 180 bytes of memory map descriptors. Only the first descriptor is used to show a continuous chunk of free memory like this:
Start of Free RAM: 0x100000 (1048576)
Size of Free RAM: 0x1BEF0000 (468647936)
As it can be seen, the useable memory is taken just after the first physical megabyte, and up to the end of the installed 512Mb. The last 64Mb are reserved for video memory, and also a chunk of 65536 bytes that presumably is a BIOS copy and those are discounted.
So, my question is if somebody has seen a PC (no more than 2 years old) with a certain amount of RAM and that has reserved memory areas in the middle of all RAM. At least, the PC in which I work only reserves towards the end of installed RAM and thus it's fairly easy to manage.
But a PC with one or more reserved areas in the middle of RAM seems to be very weird and would highly overcomplicate an otherwise clean flat memory management.
So, my question again, has somebody seen a PC that is no more than 2 years old with "memory holes" (reserved areas) in arbitrary places of RAM before the very end of the installed RAM?
General Memory / Map Question
I haven't seen. But even if there are such PC's where you see a problem?
If you want to have memory manager you need to read this table and on its base mark pages as: free or special/hardware in your page management system (PMS) which could be using stacks or bitmaps.
To do so, you need just to read every entry in ACPI table and align down to 4KB boundary its beginning adress and align top to 4KB its finish adres after reading its size from this table. Then after reading its type you can mark this area in your PMS.
I hope it will help you .
If you want to have memory manager you need to read this table and on its base mark pages as: free or special/hardware in your page management system (PMS) which could be using stacks or bitmaps.
To do so, you need just to read every entry in ACPI table and align down to 4KB boundary its beginning adress and align top to 4KB its finish adres after reading its size from this table. Then after reading its type you can mark this area in your PMS.
I hope it will help you .