linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/17] Provide lockdep tracking for bit spin locks
@ 2021-04-09  2:51 Matthew Wilcox (Oracle)
  2021-04-09  2:51 ` [PATCH 01/17] x86: Rename split_lock_init to sld_init Matthew Wilcox (Oracle)
                   ` (16 more replies)
  0 siblings, 17 replies; 28+ messages in thread
From: Matthew Wilcox (Oracle) @ 2021-04-09  2:51 UTC (permalink / raw)
  To: neilb, peterz, mingo, will, longman, boqun.feng, tglx, bigeasy
  Cc: Matthew Wilcox (Oracle), linux-kernel

Since bit spin locks are only a single bit, there's nowhere to put
a lockdep map.  Fortunately, all bit spin locks in the kernel are
conceptually in only a few classes of lock, and by introducing the
split_lock as somewhere to store the lockdep_map, we can track each bit
spin lock's dependencies.

This split_lock would also give us somewhere to queue waiters, should we
choose to do that.  Or a centralised place to handle PREEMPT_RT mutexes.
But I'll leave that for someone who knows what they're doing; for now
this keeps the same implementation.

Matthew Wilcox (Oracle) (17):
  x86: Rename split_lock_init to sld_init
  locking: Add split_lock
  bit_spinlock: Prepare for split_locks
  hlist_bl: Prepare for split_locks
  dm-snap: Add dm_exceptional_lock
  dcache: Add d_hash_lock
  fscache: Add cookie_hash_lock
  gfs2: Add qd_hash_lock
  mbcache: Add mb_cache_lock
  hlist_bl: Make the split_lock parameter mandatory
  s390: Add airq_iv_lock
  zram: Add zram_table_lock
  jbd2: Add jbd2_jh_lock
  slub: Add slab_page_lock
  zsmalloc: Add zs_pin_lock
  rhashtable: Convert to split_lock
  bit_spinlock: Track bit spin locks with lockdep

 arch/s390/include/asm/airq.h  |  5 +++--
 arch/x86/kernel/cpu/intel.c   |  6 +++---
 drivers/block/zram/zram_drv.c |  8 ++++---
 drivers/md/dm-snap.c          | 10 +++++----
 drivers/s390/cio/airq.c       |  3 +++
 fs/dcache.c                   | 25 +++++++++++-----------
 fs/fscache/cookie.c           | 13 ++++++------
 fs/gfs2/quota.c               |  5 +++--
 fs/jbd2/journal.c             | 18 +++++++++-------
 fs/mbcache.c                  | 25 +++++++++++-----------
 include/linux/bit_spinlock.h  | 39 ++++++++++++++++++++++++++++++-----
 include/linux/jbd2.h          | 10 +++++----
 include/linux/list_bl.h       | 15 ++++++++++----
 include/linux/rhashtable.h    | 20 +++++++-----------
 include/linux/split_lock.h    | 37 +++++++++++++++++++++++++++++++++
 lib/rhashtable.c              |  5 +----
 mm/slub.c                     |  6 ++++--
 mm/zsmalloc.c                 | 11 +++++++---
 18 files changed, 174 insertions(+), 87 deletions(-)
 create mode 100644 include/linux/split_lock.h

-- 
2.30.2


^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2021-05-11  7:46 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-09  2:51 [PATCH 00/17] Provide lockdep tracking for bit spin locks Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 01/17] x86: Rename split_lock_init to sld_init Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 02/17] locking: Add split_lock Matthew Wilcox (Oracle)
2021-04-12 14:29   ` Thomas Gleixner
2021-04-12 14:45     ` Matthew Wilcox
2021-04-12 15:01       ` Thomas Gleixner
2021-05-11  7:46       ` Peter Zijlstra
2021-04-09  2:51 ` [PATCH 03/17] bit_spinlock: Prepare for split_locks Matthew Wilcox (Oracle)
2021-04-09 14:32   ` Theodore Ts'o
2021-04-09 14:35     ` Matthew Wilcox
2021-04-09 14:55       ` Theodore Ts'o
2021-04-09  2:51 ` [PATCH 04/17] hlist_bl: " Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 05/17] dm-snap: Add dm_exceptional_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 06/17] dcache: Add d_hash_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 07/17] fscache: Add cookie_hash_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 08/17] gfs2: Add qd_hash_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 09/17] mbcache: Add mb_cache_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 10/17] hlist_bl: Make the split_lock parameter mandatory Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 11/17] s390: Add airq_iv_lock Matthew Wilcox (Oracle)
2021-04-09  6:18   ` kernel test robot
2021-04-09 13:20     ` Matthew Wilcox
2021-04-09  2:51 ` [PATCH 12/17] zram: Add zram_table_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 13/17] jbd2: Add jbd2_jh_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 14/17] slub: Add slab_page_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 15/17] zsmalloc: Add zs_pin_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 16/17] rhashtable: Convert to split_lock Matthew Wilcox (Oracle)
2021-04-09  2:51 ` [PATCH 17/17] bit_spinlock: Track bit spin locks with lockdep Matthew Wilcox (Oracle)
2021-04-09  6:37   ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).