From e5c5efe2ad8dc59d7aec684c13357b6cb7e0a493 Mon Sep 17 00:00:00 2001 From: Timo Kreuzer Date: Sun, 26 Nov 2023 20:17:19 +0200 Subject: [PATCH] [NTOS:KE/x64] Set the idle thread's IdealProcessor for application processors --- ntoskrnl/ke/amd64/krnlinit.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ntoskrnl/ke/amd64/krnlinit.c b/ntoskrnl/ke/amd64/krnlinit.c index 4327cd1aa7e..234628a3d46 100644 --- a/ntoskrnl/ke/amd64/krnlinit.c +++ b/ntoskrnl/ke/amd64/krnlinit.c @@ -126,6 +126,7 @@ KiInitializeHandBuiltThread( KeInitializeThread(Process, Thread, NULL, NULL, NULL, NULL, NULL, Stack); Thread->NextProcessor = Prcb->Number; + Thread->IdealProcessor = Prcb->Number; Thread->Priority = HIGH_PRIORITY; Thread->State = Running; Thread->Affinity = (ULONG_PTR)1 << Prcb->Number;