Skip to content

Siwtch to on-stack variables for block reserves

David Sterba linux-btrfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5btrfs: use on-stack variable for block reserve in btrfs_evict_inodefs/btrfs/inode.c+12 -130 replies
2/5btrfs: use on-stack variable for block reserve in btrfs_truncatefs/btrfs/inode.c+10 -120 replies
3/5btrfs: use on-stack variable for block reserve in btrfs_replace_file_extentsfs/btrfs/file.c+12 -170 replies
4/5btrfs: relocation: embed block reserve to struct reloc_controlfs/btrfs/relocation.c+21 -250 replies
5/5btrfs: remove unused alloc and free helpers for block group reservesfs/btrfs/block-rsv.c fs/btrfs/block-rsv.h+0 -260 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/5] Siwtch to on-stack variables for block reserves

The block reserve structure is small enough to fit on stack so do that in a few functions and avoid allocation. This in turn allows to remove the alloc/free wrappers.

David Sterba (5):
btrfs: use on-stack variable for block reserve in btrfs_evict_inode
btrfs: use on-stack variable for block reserve in btrfs_truncate
btrfs: use on-stack variable for block reserve in btrfs_replace_file_extents
btrfs: relocation: embed block reserve to struct reloc_control
btrfs: remove unused alloc and free helpers for block group reserves

 fs/btrfs/block-rsv.c  | 22 --------------------
 fs/btrfs/block-rsv.h  |  4 ----
 fs/btrfs/file.c       | 29 +++++++++++---------------
 fs/btrfs/inode.c      | 47 ++++++++++++++++++++-----------------------
 fs/btrfs/relocation.c | 46 +++++++++++++++++++-----------------------
 5 files changed, 55 insertions(+), 93 deletions(-)
Signature · 1 line
2.41.0