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>
This commit is contained in:
committed by
Dmitry Torokhov
parent
86255d9d0b
commit
4dfbb9d8c6
@ -823,7 +823,7 @@ static void inline sock_lock_init(struct sock *sk)
|
||||
af_family_slock_key_strings[sk->sk_family]);
|
||||
lockdep_init_map(&sk->sk_lock.dep_map,
|
||||
af_family_key_strings[sk->sk_family],
|
||||
af_family_keys + sk->sk_family);
|
||||
af_family_keys + sk->sk_family, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user