X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=KernelLand%2FKernel%2Finclude%2Fthreads_int.h;h=48452649d093854dea58e5914bcd6794be69b931;hb=73b82d524a5b6e9baf2f541bb3fccd4d7e2e94ef;hp=881db4ab0552bfbf891e8095847cefc2f40d0392;hpb=03522f70735d2db32e52e2fd5388439570ab0d0f;p=tpg%2Facess2.git diff --git a/KernelLand/Kernel/include/threads_int.h b/KernelLand/Kernel/include/threads_int.h index 881db4ab..48452649 100644 --- a/KernelLand/Kernel/include/threads_int.h +++ b/KernelLand/Kernel/include/threads_int.h @@ -71,7 +71,10 @@ struct sThread struct sProcess *Process; //!< Thread Group / Process struct sThread *Parent; //!< Parent Thread char *ThreadName; //!< Name of thread - + + struct sThread *LastDeadChild; //!< Last child to die (will have the \a DeadChildren lock) + tMutex DeadChildLock; //!< Lock to prevent clobbering of \a LastDeadChild, acquired by child, released by parent + // --- arch/proc.c's responsibility //! Kernel Stack Base tVAddr KernelStack; @@ -102,7 +105,7 @@ struct sThread }; -enum { +enum eThreadStatus { THREAD_STAT_NULL, // Invalid process THREAD_STAT_ACTIVE, // Running and schedulable process THREAD_STAT_SLEEPING, // Message Sleep