Skip to content

Commit 39ab07f

Browse files
author
Sir Richard
committed
[NTOS]: MiSetConsumer no longer achieves anything. Remove it.
svn path=/trunk/; revision=48938
1 parent eaff9c1 commit 39ab07f

File tree

2 files changed

+2
-11
lines changed

2 files changed

+2
-11
lines changed

reactos/ntoskrnl/mm/balance.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -234,8 +234,6 @@ MiIsBalancerThread(VOID)
234234
PsGetCurrentThread() == MiBalancerThreadId.UniqueThread;
235235
}
236236

237-
VOID NTAPI MiSetConsumer(IN PFN_NUMBER Pfn, IN ULONG Consumer);
238-
239237
NTSTATUS
240238
NTAPI
241239
MmRequestPageMemoryConsumer(ULONG Consumer, BOOLEAN CanWait,
@@ -321,7 +319,6 @@ MmRequestPageMemoryConsumer(ULONG Consumer, BOOLEAN CanWait,
321319
KeBugCheck(NO_PAGES_AVAILABLE);
322320
}
323321
/* Update the Consumer and make the page active */
324-
MiSetConsumer(Page, Consumer);
325322
if(Consumer == MC_USER) MmInsertLRULastUserPage(Page);
326323
*AllocatedPage = Page;
327324
(void)InterlockedDecrementUL(&MiPagesRequired);

reactos/ntoskrnl/mm/freelist.c

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -565,14 +565,6 @@ MmIsPageInUse(PFN_NUMBER Pfn)
565565
return MiIsPfnInUse(MiGetPfnEntry(Pfn));
566566
}
567567

568-
VOID
569-
NTAPI
570-
MiSetConsumer(IN PFN_NUMBER Pfn,
571-
IN ULONG Type)
572-
{
573-
MiGetPfnEntry(Pfn)->u3.e1.PageLocation = ActiveAndValid;
574-
}
575-
576568
VOID
577569
NTAPI
578570
MmDereferencePage(PFN_NUMBER Pfn)
@@ -591,6 +583,7 @@ MmDereferencePage(PFN_NUMBER Pfn)
591583
Page->u3.e1.PageLocation = ActiveAndValid;
592584

593585
/* Bring it back into the free list */
586+
DPRINT("Legacy free: %lx\n", Pfn);
594587
MiInsertPageInFreeList(Pfn);
595588
}
596589
}
@@ -617,6 +610,7 @@ MmAllocPage(ULONG Type)
617610
return 0;
618611
}
619612

613+
DPRINT("Legacy allocate: %lx\n", PfnOffset);
620614
Pfn1 = MiGetPfnEntry(PfnOffset);
621615
Pfn1->u3.e2.ReferenceCount = 1;
622616
Pfn1->u3.e1.PageLocation = ActiveAndValid;

0 commit comments

Comments
 (0)