--- Gnu-Mach/kern/thread.h 2020/09/02 04:41:17 1.1.1.2 +++ Gnu-Mach/kern/thread.h 2020/09/02 04:45:23 1.1.1.3 @@ -34,12 +34,6 @@ #ifndef _KERN_THREAD_H_ #define _KERN_THREAD_H_ -#include -#include -#include -#include -#include - #include #include #include @@ -49,11 +43,11 @@ #include #include #include +#include #include #include #include #include /* event_t, continuation_t */ -#include #include #include #include @@ -160,9 +154,6 @@ struct thread { struct ipc_port *ith_self; /* not a right, doesn't hold ref */ struct ipc_port *ith_sself; /* a send right */ struct ipc_port *ith_exception; /* a send right */ -#if MACH_IPC_COMPAT - struct ipc_port *ith_reply; /* a send right */ -#endif /* MACH_IPC_COMPAT */ mach_port_t ith_mig_reply; /* reply port for mig */ struct ipc_port *ith_rpc_reply; /* reply port for kernel RPCs */ @@ -220,10 +211,6 @@ struct thread { #if NCPUS > 1 processor_t last_processor; /* processor this last ran on */ #endif /* NCPUS > 1 */ - -#if NET_ATM - nw_ep_owned_t nw_ep_waited; -#endif /* NET_ATM */ }; /* typedef of thread_t is in kern/kern_types.h */ @@ -278,6 +265,31 @@ extern kern_return_t thread_resume( thread_t thread); extern kern_return_t thread_abort( thread_t thread); +extern void thread_start( + thread_t thread, + continuation_t start); +extern thread_t kernel_thread( + task_t task, + continuation_t start, + void *arg); +extern kern_return_t thread_priority( + thread_t thread, + int priority, + boolean_t set_max); +extern void thread_set_own_priority( + int priority); +extern kern_return_t thread_max_priority( + thread_t thread, + processor_set_t pset, + int max_priority); +extern kern_return_t thread_policy( + thread_t thread, + int policy, + int data); +extern void consider_thread_collect( + void); +extern void stack_privilege( + thread_t thread); extern kern_return_t thread_get_state( thread_t thread, int flavor, @@ -306,6 +318,7 @@ extern kern_return_t thread_assign( processor_set_t new_pset); extern kern_return_t thread_assign_default( thread_t thread); +extern void stack_collect(void); #endif /*