mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
Revert "[NTOS:MM] Do proper checks & acquire proper locks when sweeping user pages"
This reverts commit 7c006df7e0
.
Note to self: This is what happens when you have too many branch and push the wrong one.
This commit is contained in:
parent
7c006df7e0
commit
676dc4b441
1 changed files with 7 additions and 14 deletions
|
@ -213,14 +213,10 @@ MmTrimUserMemory(ULONG Target, ULONG Priority, PULONG NrFreedPages)
|
|||
|
||||
MmLockAddressSpace(&Process->Vm);
|
||||
|
||||
if (!Process->VmDeleted)
|
||||
{
|
||||
MiLockProcessWorkingSetUnsafe(Process, PsGetCurrentThread());
|
||||
|
||||
/* Be sure this is still valid. */
|
||||
if (MmIsAddressValid(Address))
|
||||
{
|
||||
PMMPTE Pte = MiAddressToPte(Address);
|
||||
if (Pte->u.Hard.Valid)
|
||||
{
|
||||
Accessed = Accessed || Pte->u.Hard.Accessed;
|
||||
Pte->u.Hard.Accessed = 0;
|
||||
|
||||
|
@ -228,9 +224,6 @@ MmTrimUserMemory(ULONG Target, ULONG Priority, PULONG NrFreedPages)
|
|||
//KeInvalidateTlbEntry(Address);
|
||||
}
|
||||
|
||||
MiUnlockProcessWorkingSet(Process, PsGetCurrentThread());
|
||||
}
|
||||
|
||||
MmUnlockAddressSpace(&Process->Vm);
|
||||
|
||||
KeUnstackDetachProcess(&ApcState);
|
||||
|
|
Loading…
Reference in a new issue