From 134a214bded9d62d9c27824bb81faad32b679e8d Mon Sep 17 00:00:00 2001 From: "Chloe M." Date: Tue, 14 Jul 2026 22:13:39 +0000 Subject: [PATCH] ptos: kpcr: Store current thread per processor Signed-off-by: Chloe M. --- service/ptos/head/hal/kpcr.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/service/ptos/head/hal/kpcr.h b/service/ptos/head/hal/kpcr.h index 7ae2e1f..1c4d934 100644 --- a/service/ptos/head/hal/kpcr.h +++ b/service/ptos/head/hal/kpcr.h @@ -11,6 +11,7 @@ #include #include +#include #include #include @@ -21,12 +22,14 @@ * @Id: Logical processor ID assigned by us * @PoolRegion: Allocator pool region * @SchedQueue: Per-core scheduler queue + * @CurrentThread: Currently running thread * @Mcb: Machine core block */ typedef struct { USHORT Id; POOL_REGION PoolRegion; SCHED_QUEUE SchedQueue; + THREAD *CurrentThread; MCB Mcb; } KPCR;