[NTOS:MM] Fix a bug in MiBuildPfnDatabase

MxPfnAllocation is in pages, not in bytes!
This commit is contained in:
Timo Kreuzer 2017-12-19 15:17:35 +01:00
parent 18cd763160
commit 12e2c48a25

View file

@ -610,9 +610,9 @@ MiBuildPfnDatabase(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
/* Map the PDEs and PPEs for the pfn database (ignore holes) */ /* Map the PDEs and PPEs for the pfn database (ignore holes) */
#if (_MI_PAGING_LEVELS >= 3) #if (_MI_PAGING_LEVELS >= 3)
MiMapPPEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + MxPfnAllocation - 1); MiMapPPEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + (MxPfnAllocation * PAGE_SIZE) - 1);
#endif #endif
MiMapPDEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + MxPfnAllocation - 1); MiMapPDEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + (MxPfnAllocation * PAGE_SIZE) - 1);
/* First initialize the color tables */ /* First initialize the color tables */
MiInitializeColorTables(); MiInitializeColorTables();