https://git.reactos.org/?p=reactos.git;a=commitdiff;h=190f710942b7f6cb45307c...
commit 190f710942b7f6cb45307ca51afcd14b7a0f9ada Author: Thamatip Chitpong thamatip.chitpong@reactos.org AuthorDate: Thu Dec 26 16:34:21 2024 +0700 Commit: Thamatip Chitpong thamatip.chitpong@reactos.org CommitDate: Wed Jan 15 16:10:55 2025 +0700
[NTOS:MM] MiBalancerThread: Formatting fixes --- ntoskrnl/mm/balance.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/ntoskrnl/mm/balance.c b/ntoskrnl/mm/balance.c index eb5e6f1d05f..6e3c51f9ded 100644 --- a/ntoskrnl/mm/balance.c +++ b/ntoskrnl/mm/balance.c @@ -349,20 +349,20 @@ CcRosTrimCache( _In_ ULONG Target, _Out_ PULONG NrFreed);
-VOID NTAPI +VOID +NTAPI MiBalancerThread(PVOID Unused) { PVOID WaitObjects[2]; NTSTATUS Status; - ULONG i;
WaitObjects[0] = &MiBalancerEvent; WaitObjects[1] = &MiBalancerTimer;
- while (1) + while (TRUE) { KeSetEvent(&MiBalancerDoneEvent, IO_NO_INCREMENT, FALSE); - Status = KeWaitForMultipleObjects(2, + Status = KeWaitForMultipleObjects(_countof(WaitObjects), WaitObjects, WaitAny, Executive, @@ -382,7 +382,7 @@ MiBalancerThread(PVOID Unused) ULONG OldTarget = InitialTarget;
/* Trim each consumer */ - for (i = 0; i < MC_MAXIMUM; i++) + for (ULONG i = 0; i < MC_MAXIMUM; i++) { InitialTarget = MiTrimMemoryConsumer(i, InitialTarget); } @@ -397,7 +397,7 @@ MiBalancerThread(PVOID Unused)
/* No pages left to swap! */ if (InitialTarget != 0 && - InitialTarget == OldTarget) + InitialTarget == OldTarget) { /* Game over */ KeBugCheck(NO_PAGES_AVAILABLE);