Skip to content

Kill fs_info::volume_mutex

David Sterba linux-btrfs 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest16 patches 18 repliesIn review
  2. v116 patches 30 repliesSuperseded

Changes in v2 from the cover letter

- sanity check in balance resume is only a warning
- read-only check in balance cancel remains and is only moved
- typo fixes

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/16btrfs: squeeze btrfs_dev_replace_continue_on_mount to its callerfs/btrfs/dev-replace.c+3 -130 replies
2/16btrfs: make success path out of btrfs_init_dev_replace_tgtdev more clearfs/btrfs/dev-replace.c fs/btrfs/volumes.c+7 -20 replies
3/16btrfs: export and rename free_devicefs/btrfs/volumes.c fs/btrfs/volumes.h+13 -120 replies
4/16btrfs: move btrfs_init_dev_replace_tgtdev to dev-replace.c and make staticfs/btrfs/dev-replace.c fs/btrfs/volumes.c fs/btrfs/volumes.h+99 -1030 replies
5/16btrfs: move volume_mutex to callers of btrfs_rm_devicefs/btrfs/ioctl.c fs/btrfs/volumes.c+4 -20 replies
6/16btrfs: move clearing of EXCL_OP out of __cancel_balancefs/btrfs/ioctl.c fs/btrfs/volumes.c+8 -72 replies
7/16btrfs: add proper safety check before resuming dev-replacefs/btrfs/dev-replace.c+11 -12 replies
8/16btrfs: add sanity check when resuming balance after mountfs/btrfs/volumes.c+13 -11 reply
9/16btrfs: cleanup helpers that reset balance statefs/btrfs/ioctl.c fs/btrfs/volumes.c+17 -203 replies
10/16btrfs: remove wrong use of volume_mutex from btrfs_dev_replace_startfs/btrfs/dev-replace.c fs/btrfs/volumes.c+1 -100 replies
11/16btrfs: kill btrfs_fs_info::volume_mutexfs/btrfs/ctree.h fs/btrfs/disk-io.c fs/btrfs/extent-tree.c +2 more+15 -420 replies
12/16btrfs: track running balance in a simpler wayfs/btrfs/ctree.h fs/btrfs/disk-io.c fs/btrfs/ioctl.c +1 more+18 -136 replies
13/16btrfs: move and comment read-only check in btrfs_cancel_balancefs/btrfs/volumes.c+8 -34 replies
14/16btrfs: drop lock parameter from update_ioctl_balance_args and renamefs/btrfs/ctree.h fs/btrfs/ioctl.c fs/btrfs/volumes.c+7 -111 reply
15/16btrfs: use mutex in btrfs_resume_balance_asyncfs/btrfs/volumes.c+3 -31 reply
16/16btrfs: open code set_balance_controlfs/btrfs/volumes.c+8 -170 replies

Reviews trailers per patch

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

PatchAnand JainNikolay Borisov
1/16R-b
2/16R-b
3/16R-b
4/16R-b
5/16R-b
6/16R-b R-b
7/16R-b R-b
8/16R-b
9/16R-b
10/16R-b
11/16R-b
12/16R-b
13/16R-b
14/16R-b
15/16R-b
16/16R-b

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

Read the v2 thread

Cover letter [PATCH v2 00/16] Kill fs_info::volume_mutex

This series gets rid of the volume mutex because it's redundant. Updated
branch: git://github.com/kdave/btrfs-devel dev/remove-volume-mutex

Changes for v2:
- sanity check in balance resume is only a warning
- read-only check in balance cancel remains and is only moved
- typo fixes

The fstests seem to pass all relevant tests now and qualifies for conditional addition to for-next.

David Sterba (16):
btrfs: squeeze btrfs_dev_replace_continue_on_mount to its caller
btrfs: make success path out of btrfs_init_dev_replace_tgtdev more clear
btrfs: export and rename free_device
btrfs: move btrfs_init_dev_replace_tgtdev to dev-replace.c and make static
btrfs: move volume_mutex to callers of btrfs_rm_device
btrfs: move clearing of EXCL_OP out of __cancel_balance
btrfs: add proper safety check before resuming dev-replace
btrfs: add sanity check when resuming balance after mount
btrfs: cleanup helpers that reset balance state
btrfs: remove wrong use of volume_mutex from btrfs_dev_replace_start
btrfs: kill btrfs_fs_info::volume_mutex
btrfs: track running balance in a simpler way
btrfs: move and comment read-only check in btrfs_cancel_balance
btrfs: drop lock parameter from update_ioctl_balance_args and rename
btrfs: use mutex in btrfs_resume_balance_async
btrfs: open code set_balance_control

 fs/btrfs/ctree.h       |   9 +-
 fs/btrfs/dev-replace.c | 135 +++++++++++++++++++++----
 fs/btrfs/disk-io.c     |   2 -
 fs/btrfs/extent-tree.c |   2 +-
 fs/btrfs/ioctl.c       |  41 +++-----
 fs/btrfs/volumes.c     | 263 +++++++++++++++----------------------------------
 fs/btrfs/volumes.h     |   5 +-
 7 files changed, 216 insertions(+), 241 deletions(-)
Signature · 1 line
2.16.2