mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[NTOS:MM] Add some DPRINTs when incrementing or decrementing PFN share count
This commit is contained in:
parent
a80ae8f2ea
commit
8bfba59b3e
1 changed files with 11 additions and 0 deletions
|
@ -978,6 +978,8 @@ MiInitializePfn(IN PFN_NUMBER PageFrameIndex,
|
|||
Pfn1 = MI_PFN_ELEMENT(PageFrameIndex);
|
||||
Pfn1->PteAddress = PointerPte;
|
||||
|
||||
DPRINT("Called for %p from %p\n", Pfn1, _ReturnAddress());
|
||||
|
||||
/* Check if this PFN is part of a valid address space */
|
||||
if (PointerPte->u.Hard.Valid == 1)
|
||||
{
|
||||
|
@ -1049,6 +1051,8 @@ MiInitializePfnAndMakePteValid(IN PFN_NUMBER PageFrameIndex,
|
|||
Pfn1->PteAddress = PointerPte;
|
||||
Pfn1->OriginalPte = DemandZeroPte;
|
||||
|
||||
DPRINT("Incrementing %p from %p\n", Pfn1, _ReturnAddress());
|
||||
|
||||
/* Otherwise this is a fresh page -- set it up */
|
||||
ASSERT(Pfn1->u3.e2.ReferenceCount == 0);
|
||||
Pfn1->u3.e2.ReferenceCount++;
|
||||
|
@ -1082,6 +1086,7 @@ MiInitializePfnAndMakePteValid(IN PFN_NUMBER PageFrameIndex,
|
|||
/* Increase its share count so we don't get rid of it */
|
||||
Pfn1 = MI_PFN_ELEMENT(PageFrameIndex);
|
||||
Pfn1->u2.ShareCount++;
|
||||
DPRINT("Incrementing %p from %p\n", Pfn1, _ReturnAddress());
|
||||
|
||||
/* Write valid PTE */
|
||||
MI_WRITE_VALID_PTE(PointerPte, TempPte);
|
||||
|
@ -1140,6 +1145,8 @@ MiDecrementShareCount(IN PMMPFN Pfn1,
|
|||
ASSERT(Pfn1 == MI_PFN_ELEMENT(PageFrameIndex));
|
||||
ASSERT(MI_IS_ROS_PFN(Pfn1) == FALSE);
|
||||
|
||||
DPRINT("Decrementing %p from %p\n", Pfn1, _ReturnAddress());
|
||||
|
||||
/* Page must be in-use */
|
||||
if ((Pfn1->u3.e1.PageLocation != ActiveAndValid) &&
|
||||
(Pfn1->u3.e1.PageLocation != StandbyPageList))
|
||||
|
@ -1289,6 +1296,8 @@ MiInitializePfnForOtherProcess(IN PFN_NUMBER PageFrameIndex,
|
|||
/* Make this a software PTE */
|
||||
MI_MAKE_SOFTWARE_PTE(&Pfn1->OriginalPte, MM_READWRITE);
|
||||
|
||||
DPRINT("Called for %p from %p\n", Pfn1, _ReturnAddress());
|
||||
|
||||
/* Setup the page */
|
||||
ASSERT(Pfn1->u3.e2.ReferenceCount == 0);
|
||||
Pfn1->u3.e2.ReferenceCount = 1;
|
||||
|
@ -1305,6 +1314,8 @@ MiInitializePfnForOtherProcess(IN PFN_NUMBER PageFrameIndex,
|
|||
|
||||
/* Increase its share count so we don't get rid of it */
|
||||
Pfn1 = MI_PFN_ELEMENT(PteFrame);
|
||||
|
||||
DPRINT("Incrementing %p from %p\n", Pfn1, _ReturnAddress());
|
||||
Pfn1->u2.ShareCount++;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue