Update initial thread and process affinity assignment to use group-aware structures

This commit is contained in:
2026-06-01 20:40:34 +02:00
parent 2fcbc7bee8
commit 615d253bb4
2 changed files with 6 additions and 4 deletions

View File

@@ -118,9 +118,10 @@ KE::KernelInit::BootstrapKernel(VOID)
CurrentThread->NextProcessor = Prcb->CpuNumber;
CurrentThread->Priority = THREAD_HIGH_PRIORITY;
CurrentThread->State = Running;
CurrentThread->Affinity = (ULONG_PTR)1 << Prcb->CpuNumber;
CurrentThread->Affinity.Mask = (KAFFINITY)1 << Prcb->CpuNumber;
CurrentThread->Affinity.Group = 0;
CurrentThread->WaitRunLevel = DISPATCH_LEVEL;
CurrentProcess->ActiveProcessors |= (ULONG_PTR)1 << Prcb->CpuNumber;
CurrentProcess->ActiveProcessors.Bitmap[0] |= (KAFFINITY)1 << Prcb->CpuNumber;
/* Initialize Memory Manager */
MM::Manager::InitializeMemoryManager();