// Now move to the first free system PTE cluster
//
PreviousPte = PointerPte;
- PointerPte = MmSystemPteBase + PointerPte->u.List.NextEntry;
+ PointerPte = MmSystemPtesStart[SystemPtePoolType] +
+ PointerPte->u.List.NextEntry;
//
// Loop each cluster
// Go to the next cluster
//
PreviousPte = PointerPte;
- PointerPte = MmSystemPteBase + PointerPte->u.List.NextEntry;
+ PointerPte = MmSystemPtesStart[SystemPtePoolType] +
+ PointerPte->u.List.NextEntry;
ASSERT(PointerPte > PreviousPte);
}
// Zero PTEs
//
RtlZeroMemory(StartingPte, NumberOfPtes * sizeof(MMPTE));
- CurrentSize = (ULONG_PTR)(StartingPte - MmSystemPteBase);
+ CurrentSize = (ULONG_PTR)(StartingPte - MmSystemPtesStart[SystemPtePoolType]);
//
// Acquire the system PTE lock
//
// Get the first real cluster of PTEs and check if it's ours
//
- PointerPte = MmSystemPteBase + CurrentPte->u.List.NextEntry;
+ PointerPte = MmSystemPtesStart[SystemPtePoolType] +
+ CurrentPte->u.List.NextEntry;
if (CurrentSize < CurrentPte->u.List.NextEntry)
{
//
StartingPte->u.List.NextEntry = ((ULONG)0xFFFFF);
MmFirstFreeSystemPte[PoolType].u.Long = 0;
MmFirstFreeSystemPte[PoolType].u.List.NextEntry = StartingPte -
- MmSystemPteBase;
+ MmSystemPtesStart[PoolType];
//
// The second entry stores the size of this PTE space