https://git.reactos.org/?p=reactos.git;a=commitdiff;h=8494688eebecb287973569dc1261fd0741706324
commit 8494688eebecb287973569dc1261fd0741706324 Author: Jérôme Gardou <[email protected]> AuthorDate: Thu Mar 18 09:05:00 2021 +0100 Commit: Jérôme Gardou <[email protected]> CommitDate: Thu Mar 18 12:24:21 2021 +0100 [NTOS:MM] Do not use atomic operations to set a bit while holding a lock. Saving your fingers from typing it doesn't make it better code. --- ntoskrnl/mm/ARM3/expool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ntoskrnl/mm/ARM3/expool.c b/ntoskrnl/mm/ARM3/expool.c index fb55f9159ba..95bc21ad822 100644 --- a/ntoskrnl/mm/ARM3/expool.c +++ b/ntoskrnl/mm/ARM3/expool.c @@ -1734,7 +1734,7 @@ ExpFindAndRemoveTagBigPages(IN PVOID Va, // Set the free bit, and decrement the number of allocations. Finally, release // the lock and return the tag that was located // - InterlockedIncrement((PLONG)&Entry->Va); + Entry->Va = (PVOID)((ULONG_PTR)Entry->Va | POOL_BIG_TABLE_ENTRY_FREE); ExpPoolBigEntriesInUse--;
