Skip to content

btrfs: cleanups and small fixes mostly around block reserves

[email protected] linux-btrfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest24 patches 22 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/24btrfs: pass a bool to btrfs_block_rsv_migrate() at evict_refill_and_join()fs/btrfs/inode.c+1 -12 replies
2/24btrfs: pass a bool size update argument to btrfs_block_rsv_add_bytes()fs/btrfs/delayed-ref.c+1 -12 replies
3/24btrfs: remove check for NULL block reserve at btrfs_block_rsv_check()fs/btrfs/block-rsv.c+0 -33 replies
4/24btrfs: update documentation for BTRFS_RESERVE_FLUSH_EVICT flush methodfs/btrfs/space-info.h+1 -01 reply
5/24btrfs: update flush method assertion when reserving spacefs/btrfs/space-info.c+12 -10 replies
6/24btrfs: initialize ret to -ENOSPC at __reserve_bytes()fs/btrfs/space-info.c+1 -22 replies
7/24btrfs: simplify btrfs_should_throttle_delayed_refs()fs/btrfs/delayed-ref.c fs/btrfs/delayed-ref.h+3 -51 reply
8/24btrfs: collapse should_end_transaction() into btrfs_should_end_transaction()fs/btrfs/transaction.c+4 -111 reply
9/24btrfs: remove bytes_used argument from btrfs_make_block_group()fs/btrfs/block-group.c fs/btrfs/block-group.h fs/btrfs/volumes.c+4 -71 reply
10/24btrfs: count extents before taking inode's spinlock when reserving metadatafs/btrfs/delalloc-space.c+1 -11 reply
11/24btrfs: remove redundant counter check at btrfs_truncate_inode_items()fs/btrfs/inode-item.c+1 -21 reply
12/24btrfs: simplify btrfs_block_rsv_refill()fs/btrfs/block-rsv.c fs/btrfs/block-rsv.h+2 -41 reply
13/24btrfs: remove obsolete delayed ref throttling logic when truncating itemsfs/btrfs/delayed-ref.c fs/btrfs/delayed-ref.h fs/btrfs/disk-io.c +3 more+7 -510 replies
14/24btrfs: don't throttle on delayed items when evicting deleted inodefs/btrfs/inode.c+6 -10 replies
15/24btrfs: calculate the right space for a single delayed ref when refillingfs/btrfs/delayed-ref.c+11 -01 reply
16/24btrfs: accurately calculate number of delayed refs when flushingfs/btrfs/space-info.c+25 -10 replies
17/24btrfs: constify fs_info argument of the metadata size calculation helpersfs/btrfs/fs.h+2 -21 reply
18/24btrfs: constify fs_info argument for the reclaim items calculation helpersfs/btrfs/space-info.c+2 -21 reply
19/24btrfs: add helper to calculate space for delayed referencesfs/btrfs/delayed-ref.c fs/btrfs/delayed-ref.h fs/btrfs/space-info.c+26 -490 replies
20/24btrfs: calculate correct amount of space for delayed reference when evictingfs/btrfs/inode.c+1 -10 replies
21/24btrfs: fix calculation of the global block reserve's sizefs/btrfs/block-rsv.c+3 -30 replies
22/24btrfs: use a constant for the number of metadata units needed for an unlinkfs/btrfs/block-rsv.c fs/btrfs/fs.h fs/btrfs/inode.c+20 -141 reply
23/24btrfs: calculate the right space for delayed refs when updating global reservefs/btrfs/block-rsv.c+6 -50 replies
24/24btrfs: simplify exit paths of btrfs_evict_inode()fs/btrfs/inode.c+10 -110 replies

Reviews trailers per patch

15 of 24 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchAnand JainJohannes ThumshirnJosef Bacik
SeriesR-b
1/24R-b R-b
2/24R-b R-b
3/24R-b R-b
4/24R-b
5/24
6/24R-b R-b
7/24R-b
8/24R-b
9/24R-b
10/24R-b
11/24R-b
12/24R-b
13/24
14/24
15/24R-b
16/24
17/24R-b
18/24R-b
19/24
20/24
21/24
22/24R-b
23/24
24/24

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v1 thread

Cover letter [PATCH 00/24] btrfs: cleanups and small fixes mostly around block reserves

From: Filipe Manana <[email protected]>

A set of cleanups and small fixes that started as part of a larger work, mostly around block reserves and space reservation, but as they are mostly trivial and independent of the rest of that work, I'm sending them out separately. More details on the individual changelogs.

Filipe Manana (24):
btrfs: pass a bool to btrfs_block_rsv_migrate() at evict_refill_and_join()
btrfs: pass a bool size update argument to btrfs_block_rsv_add_bytes()
btrfs: remove check for NULL block reserve at btrfs_block_rsv_check()
btrfs: update documentation for BTRFS_RESERVE_FLUSH_EVICT flush method
btrfs: update flush method assertion when reserving space
btrfs: initialize ret to -ENOSPC at __reserve_bytes()
btrfs: simplify btrfs_should_throttle_delayed_refs()
btrfs: collapse should_end_transaction() into btrfs_should_end_transaction()
btrfs: remove bytes_used argument from btrfs_make_block_group()
btrfs: count extents before taking inode's spinlock when reserving metadata
btrfs: remove redundant counter check at btrfs_truncate_inode_items()
btrfs: simplify btrfs_block_rsv_refill()
btrfs: remove obsolete delayed ref throttling logic when truncating items
btrfs: don't throttle on delayed items when evicting deleted inode
btrfs: calculate the right space for a single delayed ref when refilling
btrfs: accurately calculate number of delayed refs when flushing
btrfs: constify fs_info argument of the metadata size calculation helpers
btrfs: constify fs_info argument for the reclaim items calculation helpers
btrfs: add helper to calculate space for delayed references
btrfs: calculate correct amount of space for delayed reference when evicting
btrfs: fix calculation of the global block reserve's size
btrfs: use a constant for the number of metadata units needed for an unlink
btrfs: calculate the right space for delayed refs when updating global reserve
btrfs: simplify exit paths of btrfs_evict_inode()

 fs/btrfs/block-group.c    |  7 ++----
 fs/btrfs/block-group.h    |  2 +-
 fs/btrfs/block-rsv.c      | 21 +++++++----------
 fs/btrfs/block-rsv.h      |  2 +-
 fs/btrfs/delalloc-space.c |  2 +-
 fs/btrfs/delayed-ref.c    | 49 ++++-----------------------------------
 fs/btrfs/delayed-ref.h    | 22 +++++++++++++++++-
 fs/btrfs/disk-io.c        |  1 -
 fs/btrfs/extent-tree.c    | 27 ++-------------------
 fs/btrfs/fs.h             | 17 +++++++++++---
 fs/btrfs/inode-item.c     | 15 +++++-------
 fs/btrfs/inode.c          | 43 ++++++++++++++++------------------
 fs/btrfs/space-info.c     | 32 +++++++++++++++++++++----
 fs/btrfs/space-info.h     |  1 +
 fs/btrfs/transaction.c    | 15 ++++--------
 fs/btrfs/volumes.c        |  2 +-
 16 files changed, 115 insertions(+), 143 deletions(-)
Signature · 1 line
2.34.1