Skip to content

sb_write: lockdep fixes/cleanups

Oleg Nesterov linux-fsdevel lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 5 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4introduce __sb_{acquire,release}_write() helpersfs/btrfs/transaction.c fs/xfs/xfs_aops.c include/linux/fs.h+9 -101 reply
2/4fix the broken lockdep logic in __sb_start_write()fs/super.c+40 -332 replies
3/4move rwsem_release() from sb_wait_write() to freeze_super()fs/super.c+10 -61 reply
4/4change thaw_super() to re-acquire s_writers.lock_mapfs/super.c+12 -01 reply

Reviews trailers per patch

All 4 patches have a Reviewed-by or Acked-by.

PatchJan Kara
1/4R-b
2/4R-b
3/4R-b
4/4R-b

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

Read the v1 thread

Cover letter [PATCH 0/4] sb_write: lockdep fixes/cleanups

So this is the preparation for percpu_rw_semaphore conversion. But let me repeat, imo these changes make sense in any case, so I'd like to send them separately.

2/4 fixes 2 bugs and cleanups the "trylock" hack. Although this hack can be probably removed, see the changelog.

3/4 and 4/4 try to make the lockdep annotations more consistent. If we want to use lockdep we should not hide the "write" locks we hold when we call freeze_fs(sb) and unfreeze_fs(sb).

Please review.

Oleg.

 fs/btrfs/transaction.c |    8 +---
 fs/super.c             |  101 +++++++++++++++++++++++++++++------------------
 fs/xfs/xfs_aops.c      |    6 +--
 include/linux/fs.h     |    5 ++
 4 files changed, 71 insertions(+), 49 deletions(-)