Skip to content

Commit

Permalink
mm/slub.c: drop lockdep_assert_held() from put_map()
Browse files Browse the repository at this point in the history
There is no point in using lockdep_assert_held() unlock that is about to
be unlocked.  It works only with lockdep and lockdep will complain if
spin_unlock() is used on a lock that has not been locked.

Remove superfluous lockdep_assert_held().

Signed-off-by: Sebastian Andrzej Siewior <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Cc: Yu Zhao <[email protected]>
Cc: Christopher Lameter <[email protected]>
Cc: Pekka Enberg <[email protected]>
Cc: David Rientjes <[email protected]>
Cc: Joonsoo Kim <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Sebastian Andrzej Siewior authored and torvalds committed Aug 7, 2020
1 parent e42f174 commit b3cb9fc
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions mm/slub.c
Original file line number Diff line number Diff line change
Expand Up @@ -473,8 +473,6 @@ static unsigned long *get_map(struct kmem_cache *s, struct page *page)
static void put_map(unsigned long *map) __releases(&object_map_lock)
{
VM_BUG_ON(map != object_map);
lockdep_assert_held(&object_map_lock);

spin_unlock(&object_map_lock);
}

Expand Down

0 comments on commit b3cb9fc

Please sign in to comment.