diff options
author | Justus Winter <4winter@informatik.uni-hamburg.de> | 2015-07-25 02:29:58 +0200 |
---|---|---|
committer | Justus Winter <4winter@informatik.uni-hamburg.de> | 2015-09-14 14:45:05 +0200 |
commit | fd4e4f6ea4f2cbcc18f0ae6659b21b130df50066 (patch) | |
tree | c09f797af9ea34cfafb4c3ac6c89a6d13e394472 /ipc/ipc_thread.h | |
parent | de53c776ce14fe38fcc548ddc536f64fc5a42ed0 (diff) |
kern: use a general lock for the IPC structures
* ipc/ipc_thread.h (ith_{lock_init,lock,unlock}): Use a general lock.
* kern/task.h (struct task): Use a general lock for `itk_lock_data'.
(itk_{lock_init,lock,unlock}): Use a general lock.
* kern/thread.h (struct thread): Use a general lock for `ith_lock_data'.
Diffstat (limited to 'ipc/ipc_thread.h')
-rw-r--r-- | ipc/ipc_thread.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ipc/ipc_thread.h b/ipc/ipc_thread.h index 008ab4a..9e2c079 100644 --- a/ipc/ipc_thread.h +++ b/ipc/ipc_thread.h @@ -42,9 +42,9 @@ typedef thread_t ipc_thread_t; #define ITH_NULL THREAD_NULL -#define ith_lock_init(thread) simple_lock_init(&(thread)->ith_lock_data) -#define ith_lock(thread) simple_lock(&(thread)->ith_lock_data) -#define ith_unlock(thread) simple_unlock(&(thread)->ith_lock_data) +#define ith_lock_init(thread) lock_init(&(thread)->ith_lock_data, FALSE) +#define ith_lock(thread) lock_write(&(thread)->ith_lock_data) +#define ith_unlock(thread) lock_write_done(&(thread)->ith_lock_data) /* * Note that this isn't a queue, but rather a stack. This causes |