Skip to content

locking/lockdep: Add comments and make some code

Yuyang Du lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest18 patches 1 replyIn review
  2. v219 patches 17 repliesSuperseded
  3. v18 patches 0 repliesSuperseded

Changes in v3 from the cover letter

- Removed indent adjustments only patch
- Removed unnecessary if to else-if patch
- Made changes according to comments
- Added another doc addition patch

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/18locking/lockdep: Change all print_*() return type to voidkernel/locking/lockdep.c+103 -1000 replies
2/18locking/lockdep: Add description and explanation in lockdep design docDocumentation/locking/lockdep-design.txt+60 -200 replies
3/18locking/lockdep: Adjust lock usage bit character checkskernel/locking/lockdep.c kernel/locking/lockdep_internals.h+17 -50 replies
4/18locking/lockdep: Remove useless conditional macrokernel/locking/lockdep.c+3 -30 replies
5/18locking/lockdep: Print the right depth for chain key colissionkernel/locking/lockdep.c+4 -30 replies
6/18locking/lockdep: Update obsolete struct field descriptioninclude/linux/lockdep.h+8 -20 replies
7/18locking/lockdep: Use lockdep_init_task for task initiation consistentlyinclude/linux/lockdep.h init/init_task.c kernel/fork.c +1 more+16 -70 replies
8/18locking/lockdep: Define INITIAL_CHAIN_KEY for chain keys to start withinclude/linux/lockdep.h init/init_task.c kernel/locking/lockdep.c+11 -100 replies
9/18locking/lockdep: Change the range of class_idx in held_lock structinclude/linux/lockdep.h kernel/locking/lockdep.c+46 -270 replies
10/18locking/lockdep: Remove unused argument in validate_chain() and check_deadlock()kernel/locking/lockdep.c+8 -80 replies
11/18locking/lockdep: Update commentkernel/locking/lockdep.c+9 -30 replies
12/18locking/lockdep: Remove unnecessary function pointer argumentkernel/locking/lockdep.c+5 -60 replies
13/18locking/lockdep: Change type of the element field in circular_queuekernel/locking/lockdep.c+13 -100 replies
14/18locking/lockdep: Change the return type of __cq_dequeue()kernel/locking/lockdep.c+13 -80 replies
15/18locking/lockdep: Avoid constant checks in __bfs by using offset referencekernel/locking/lockdep.c+21 -120 replies
16/18locking/lockdep: Combine check_noncircular and check_redundantkernel/locking/lockdep.c+11 -200 replies
17/18locking/lockdep: Update comments on dependency searchkernel/locking/lockdep.c+10 -110 replies
18/18locking/lockdep: Add explanation to lock usage rules in lockdep design docDocumentation/locking/lockdep-design.txt+25 -101 reply

Reviews trailers per patch

3 of 18 patches have a Reviewed-by or Acked-by.

PatchBart Van Assche
1/18
2/18
3/18
4/18
5/18
6/18
7/18
8/18
9/18
10/18R-b
11/18
12/18R-b
13/18R-b
14/18
15/18
16/18
17/18
18/18

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 00/18] locking/lockdep: Add comments and make some code

Hi Peter,

I recently looked at some system hang issues. While at it, I tried to use and understand lockdep. These patches are made as a result. I believe they should have helped me, so hopefully they do for others as well.

Many thanks to Bart, Joe, and Peter for their valuable comments.

Change from v2:
- Removed indent adjustments only patch
- Removed unnecessary if to else-if patch
- Made changes according to comments
- Added another doc addition patch

Change from v1:
- Rebased the patch series.
- Added more no-functional-change patches.
- Removed zapped locks in lock chains printing patch, which was a band-aid. The real problem was recently fixed by Bart.

Thanks,
Yuyang

--

Yuyang Du (18):
locking/lockdep: Change all print_*() return type to void locking/lockdep: Add description and explanation in lockdep design doc locking/lockdep: Adjust lock usage bit character checks locking/lockdep: Remove useless conditional macro locking/lockdep: Print the right depth for chain key colission locking/lockdep: Update obsolete struct field description locking/lockdep: Use lockdep_init_task for task initiation
consistently
locking/lockdep: Define INITIAL_CHAIN_KEY for chain keys to start with locking/lockdep: Change the range of class_idx in held_lock struct locking/lockdep: Remove unused argument in validate_chain() and
check_deadlock()
locking/lockdep: Update comment
locking/lockdep: Remove unnecessary function pointer argument locking/lockdep: Change type of the element field in circular_queue locking/lockdep: Change the return type of __cq_dequeue() locking/lockdep: Avoid constant checks in __bfs by using offset
reference
locking/lockdep: Combine check_noncircular and check_redundant locking/lockdep: Update comments on dependency search locking/lockdep: Add explanation to lock usage rules in lockdep design
doc

 Documentation/locking/lockdep-design.txt | 115 ++++++--
 include/linux/lockdep.h                  |  30 +-
 init/init_task.c                         |   2 +
 kernel/fork.c                            |   3 -
 kernel/locking/lockdep.c                 | 487 +++++++++++++++++--------------
 kernel/locking/lockdep_internals.h       |   1 +
 6 files changed, 378 insertions(+), 260 deletions(-)
Signature · 1 line
1.8.3.1