diff options
| author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-07-05 13:13:03 -0400 | 
|---|---|---|
| committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-07-05 13:13:03 -0400 | 
| commit | 5e66dd6d66ffe758b39b6dcadf2330753ee1159b (patch) | |
| tree | a72cdcff4448e4af9425cc213ddf56ab23e697fe /include/linux/wait.h | |
| parent | 026477c1141b67e98e3bd8bdedb7d4b88a3ecd09 (diff) | |
| parent | ca78f6baca863afe2e6a244a0fe94b3a70211d46 (diff) | |
Merge branch 'master' of /home/trondmy/kernel/linux-2.6/
Diffstat (limited to 'include/linux/wait.h')
| -rw-r--r-- | include/linux/wait.h | 8 | 
1 files changed, 7 insertions, 1 deletions
| diff --git a/include/linux/wait.h b/include/linux/wait.h index 544e855c7c02..794be7af58ae 100644 --- a/include/linux/wait.h +++ b/include/linux/wait.h @@ -68,7 +68,7 @@ struct task_struct;  	wait_queue_t name = __WAITQUEUE_INITIALIZER(name, tsk)  #define __WAIT_QUEUE_HEAD_INITIALIZER(name) {				\ -	.lock		= SPIN_LOCK_UNLOCKED,				\ +	.lock		= __SPIN_LOCK_UNLOCKED(name.lock),		\  	.task_list	= { &(name).task_list, &(name).task_list } }  #define DECLARE_WAIT_QUEUE_HEAD(name) \ @@ -77,9 +77,15 @@ struct task_struct;  #define __WAIT_BIT_KEY_INITIALIZER(word, bit)				\  	{ .flags = word, .bit_nr = bit, } +/* + * lockdep: we want one lock-class for all waitqueue locks. + */ +extern struct lock_class_key waitqueue_lock_key; +  static inline void init_waitqueue_head(wait_queue_head_t *q)  {  	spin_lock_init(&q->lock); +	lockdep_set_class(&q->lock, &waitqueue_lock_key);  	INIT_LIST_HEAD(&q->task_list);  } | 
