https://git.reactos.org/?p=reactos.git;a=commitdiff;h=12e2c48a25240c05b73dcec86ce8ae9370b59b1c
commit 12e2c48a25240c05b73dcec86ce8ae9370b59b1c Author: Timo Kreuzer <timo.kreu...@reactos.org> AuthorDate: Tue Dec 19 15:17:35 2017 +0100 [NTOS:MM] Fix a bug in MiBuildPfnDatabase MxPfnAllocation is in pages, not in bytes! --- ntoskrnl/mm/amd64/init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ntoskrnl/mm/amd64/init.c b/ntoskrnl/mm/amd64/init.c index 2acdf596e6..1f912623a2 100644 --- a/ntoskrnl/mm/amd64/init.c +++ b/ntoskrnl/mm/amd64/init.c @@ -610,9 +610,9 @@ MiBuildPfnDatabase(IN PLOADER_PARAMETER_BLOCK LoaderBlock) /* Map the PDEs and PPEs for the pfn database (ignore holes) */ #if (_MI_PAGING_LEVELS >= 3) - MiMapPPEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + MxPfnAllocation - 1); + MiMapPPEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + (MxPfnAllocation * PAGE_SIZE) - 1); #endif - MiMapPDEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + MxPfnAllocation - 1); + MiMapPDEs(MmPfnDatabase, (PUCHAR)MmPfnDatabase + (MxPfnAllocation * PAGE_SIZE) - 1); /* First initialize the color tables */ MiInitializeColorTables();