diff options
| author | Bart Van Assche <bvanassche@acm.org> | 2018-12-06 20:11:35 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2018-12-11 08:54:54 -0500 |
| commit | a66b6922dc6a5ece60ea9326153da3b062977a4d (patch) | |
| tree | 8750550a582f2610224805b9613be5ed44093984 | |
| parent | 2904d9fa45d3ce7153f1e10d78c570ecf7f19c35 (diff) | |
locking/lockdep: Remove a superfluous INIT_LIST_HEAD() statement
Initializing a list entry just before it is passed to list_add_tail_rcu()
is not necessary because list_add_tail_rcu() overwrites the next and prev
pointers anyway. Hence remove the INIT_LIST_HEAD() statement.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sasha Levin <sasha.levin@oracle.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Waiman Long <longman@redhat.com>
Cc: johannes.berg@intel.com
Cc: tj@kernel.org
Link: https://lkml.kernel.org/r/20181207011148.251812-12-bvanassche@acm.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
| -rw-r--r-- | kernel/locking/lockdep.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/kernel/locking/lockdep.c b/kernel/locking/lockdep.c index 81388d028ac7..346b5a1fd062 100644 --- a/kernel/locking/lockdep.c +++ b/kernel/locking/lockdep.c | |||
| @@ -792,7 +792,6 @@ register_lock_class(struct lockdep_map *lock, unsigned int subclass, int force) | |||
| 792 | class->key = key; | 792 | class->key = key; |
| 793 | class->name = lock->name; | 793 | class->name = lock->name; |
| 794 | class->subclass = subclass; | 794 | class->subclass = subclass; |
| 795 | INIT_LIST_HEAD(&class->lock_entry); | ||
| 796 | INIT_LIST_HEAD(&class->locks_before); | 795 | INIT_LIST_HEAD(&class->locks_before); |
| 797 | INIT_LIST_HEAD(&class->locks_after); | 796 | INIT_LIST_HEAD(&class->locks_after); |
| 798 | class->name_version = count_matching_names(class); | 797 | class->name_version = count_matching_names(class); |
