summaryrefslogtreecommitdiffstats
path: root/lib/rwsem-spinlock.c
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2006-10-11 07:45:14 +0200
committerDmitry Torokhov <dtor@insightbb.com>2006-10-11 07:45:14 +0200
commit4dfbb9d8c6cbfc32faa5c71145bd2a43e1f8237c (patch)
treea4fefea0d5f5930240f4ecd6f9716a029cc927a9 /lib/rwsem-spinlock.c
parentInput: atkbd - supress "too many keys" error message (diff)
downloadlinux-4dfbb9d8c6cbfc32faa5c71145bd2a43e1f8237c.tar.xz
linux-4dfbb9d8c6cbfc32faa5c71145bd2a43e1f8237c.zip
Lockdep: add lockdep_set_class_and_subclass() and lockdep_set_subclass()
This annotation makes it possible to assign a subclass on lock init. This annotation is meant to reduce the _nested() annotations by assigning a default subclass. One could do without this annotation and rely on lockdep_set_class() exclusively, but that would require a manual stack of struct lock_class_key objects. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'lib/rwsem-spinlock.c')
-rw-r--r--lib/rwsem-spinlock.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rwsem-spinlock.c b/lib/rwsem-spinlock.c
index db4fed74b940..c4cfd6c0342f 100644
--- a/lib/rwsem-spinlock.c
+++ b/lib/rwsem-spinlock.c
@@ -28,7 +28,7 @@ void __init_rwsem(struct rw_semaphore *sem, const char *name,
* Make sure we are not reinitializing a held semaphore:
*/
debug_check_no_locks_freed((void *)sem, sizeof(*sem));
- lockdep_init_map(&sem->dep_map, name, key);
+ lockdep_init_map(&sem->dep_map, name, key, 0);
#endif
sem->activity = 0;
spin_lock_init(&sem->wait_lock);