mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH-tip 0/3] locking/lockdep: Cleaning up lockdep code
@ 2020-02-12 15:38 Waiman Long
  2020-02-12 15:38 ` [PATCH-tip 1/3] locking/lockdep: Make remove_class_from_lock_chains() depend on CONFIG_PROVE_LOCKING Waiman Long
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Waiman Long @ 2020-02-12 15:38 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar, Will Deacon
  Cc: linux-kernel, Bart Van Assche, Waiman Long

The following conditional compilation macros are used throughout the
lockdep code making it hard to understand.
 - CONFIG_PROVE_LOCKING
 - CONFIG_LOCK_STAT
 - CONFIG_DEBUG_LOCKDEP
 - CONFIG_LOCKDEP_SMALL
 - CONFIG_TRACE_IRQFLAGS

In particular, almost half of the code is for CONFIG_PROVE_LOCKING and
there are several blocks of them in lockdep.c. It is very hard to see if
a function is for CONFIG_PROVE_LOCKING or not.

This patchset cleans up this mess by putting all the CONFIG_PROVE_LOCKING
functions into a separate lockdep_prove.c file making it easier to know
what they are for. It also consolidates the CONFIG_DEBUG_LOCKDEP code
to a certain extend.

This is a code relocation patchset. There is no functional change.

Waiman Long (3):
  locking/lockdep: Make remove_class_from_lock_chains() depend on
    CONFIG_PROVE_LOCKING
  locking/lockdep: Extract CONFIG_PROVE_LOCKING code out to
    lockdep_prove.c
  locking/lockdep: Consolidate CONFIG_DEBUG_LOCKDEP code

 kernel/locking/lockdep.c       | 3300 +++-----------------------------
 kernel/locking/lockdep_prove.c | 2820 +++++++++++++++++++++++++++
 2 files changed, 3066 insertions(+), 3054 deletions(-)
 create mode 100644 kernel/locking/lockdep_prove.c

-- 
2.18.1


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

end of thread, other threads:[~2020-02-12 15:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-12 15:38 [PATCH-tip 0/3] locking/lockdep: Cleaning up lockdep code Waiman Long
2020-02-12 15:38 ` [PATCH-tip 1/3] locking/lockdep: Make remove_class_from_lock_chains() depend on CONFIG_PROVE_LOCKING Waiman Long
2020-02-12 15:38 ` [PATCH-tip 2/3] locking/lockdep: Extract CONFIG_PROVE_LOCKING code out to lockdep_prove.c Waiman Long
2020-02-12 15:38 ` [PATCH-tip 3/3] locking/lockdep: Consolidate CONFIG_DEBUG_LOCKDEP code Waiman Long

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome