
The driver supports the ability to allocate graphics memory dynamically by sharing system resources with the operating system or statically by pre-allocating a block of system memory to be used exclusively by the graphics driver.
To configure the driver to operate using static video memory, two registry settings “ReservedMemoryBase” and “ReservedMemorySize” need to be enabled and defined with valid values. These two registry entries control the start address and size of the memory range pre-allocated for graphics driver use. The pre-allocated memory range should include the stolen memory (BIOS setting). For the Intel chipset or processor, this feature does not reuse the stolen video memory reserved by BIOS. Intel recommends getting BIOS to limit this to the smallest size as this memory is wasted due to some combined OS and hardware limitation.
For example, on a system with 512 MB of system memory and 4 MB of stolen memory (BIOS option), if an additional 14 MB of graphics memory (for a total of 18 MB) is desired, these settings should be used.
“ReservedMemoryBase”=dword:1E400000
“ReservedMemorySize”=dword:01C00000
These settings indicate that the managed graphics memory pool will begin at physical address 0x1E400000 (484 MB) and will be 18 MB in size. The base address, “ReservedMemoryBase,” is the physical system address value and the stolen memory from the BIOS settings is included.
Check the platform you are using to ensure you have all the stolen memory taken into account. For example, in the case of the Cobra board that uses Intel's ACSFL firmware, 2 MB of stolen video memory needs to be included in this configuration. Always remember to include the amount of stolen memory in this number.
Besides the registry entry, the Platform Builder working project also needs to be updated to ensure that the kernel does not try to access this stolen memory. Two items in the config.bib of the project workspace need editing: the NK image/RAM memory partitioning and the memory reservation list. Using the example of the registry configurations above, the kernel would have to be configured not to use the physical memory above the 484 MB mark since that's where the static video memory begins. Thus, the total of the NK image and the system's available RAM must be no more than 484 MB, so you must change your config.bib accordingly:
NK 80220000 009BE0000 RAMIMAGE ;14 MB for nk.bin + misc.
RAM 80C00000 1DA00000 RAM ;42 MB for RAM
The NK.BIN image plus the lower conventional memory DMA buffers used by Windows Embedded Compact 7 takes 10 MB; 474 MB is for the RAM. Thus, the memory area above the 484 MB mark is untouched by the kernel and will be used by the display driver.
Overall solution from above example settings in terms of physical system memory viewpoint:
|
|