From 232fd3bae39bbca5dbdda34e980c2853cff1de6a Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Wed, 3 Sep 2008 14:48:47 +0000 Subject: [PATCH] Moved the wait type definitions to . We're going to use them in userland, too. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27301 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/private/kernel/thread_types.h | 14 -------------- headers/private/system/thread_defs.h | 15 +++++++++++++++ 2 files changed, 15 insertions(+), 14 deletions(-) diff --git a/headers/private/kernel/thread_types.h b/headers/private/kernel/thread_types.h index 68921d5ede..f6489145a0 100644 --- a/headers/private/kernel/thread_types.h +++ b/headers/private/kernel/thread_types.h @@ -49,20 +49,6 @@ typedef enum job_control_state { JOB_CONTROL_STATE_DEAD } job_control_state; -// The type of object a thread blocks on (thread::wait::type, set by -// thread_prepare_to_block()). -enum { - THREAD_BLOCK_TYPE_SEMAPHORE = 0, - THREAD_BLOCK_TYPE_CONDITION_VARIABLE = 1, - THREAD_BLOCK_TYPE_SNOOZE = 2, - THREAD_BLOCK_TYPE_SIGNAL = 3, - THREAD_BLOCK_TYPE_MUTEX = 4, - THREAD_BLOCK_TYPE_RW_LOCK = 5, - - THREAD_BLOCK_TYPE_OTHER = 9999, - THREAD_BLOCK_TYPE_USER_BASE = 10000 -}; - struct image; // defined in image.c struct realtime_sem_context; // defined in realtime_sem.cpp struct select_info; diff --git a/headers/private/system/thread_defs.h b/headers/private/system/thread_defs.h index 2d67e5183a..ab990190e2 100644 --- a/headers/private/system/thread_defs.h +++ b/headers/private/system/thread_defs.h @@ -24,6 +24,21 @@ - USER_STACK_GUARD_PAGES * B_PAGE_SIZE) // 16 MB +// The type of object a thread blocks on (thread::wait::type, set by +// thread_prepare_to_block()). +enum { + THREAD_BLOCK_TYPE_SEMAPHORE = 0, + THREAD_BLOCK_TYPE_CONDITION_VARIABLE = 1, + THREAD_BLOCK_TYPE_SNOOZE = 2, + THREAD_BLOCK_TYPE_SIGNAL = 3, + THREAD_BLOCK_TYPE_MUTEX = 4, + THREAD_BLOCK_TYPE_RW_LOCK = 5, + + THREAD_BLOCK_TYPE_OTHER = 9999, + THREAD_BLOCK_TYPE_USER_BASE = 10000 +}; + + struct thread_creation_attributes { int32 (*entry)(thread_func, void *); const char* name;