Skip to content

btrfs: some fixes and cleanups around btrfs_cow_block()

[email protected] linux-btrfs 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest8 patches 2 repliesIn review
  2. v18 patches 4 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8btrfs: error out when COWing block using a stale transactionfs/btrfs/ctree.c+16 -80 replies
2/8btrfs: error when COWing block from a root that is being deletedfs/btrfs/ctree.c+7 -30 replies
3/8btrfs: error out when reallocating block for defrag using a stale transactionfs/btrfs/ctree.c+16 -20 replies
4/8btrfs: remove noinline attribute from btrfs_cow_block()fs/btrfs/ctree.c+1 -10 replies
5/8btrfs: use round_down() to align block offset at btrfs_cow_block()fs/btrfs/ctree.c+1 -10 replies
6/8btrfs: rename and export __btrfs_cow_block()fs/btrfs/ctree.c fs/btrfs/ctree.h+22 -150 replies
7/8btrfs: export comp_keys() from ctree.c as btrfs_comp_keys()fs/btrfs/ctree.c fs/btrfs/ctree.h+38 -370 replies
8/8btrfs: move btrfs_realloc_node() from ctree.c into defrag.cfs/btrfs/ctree.c fs/btrfs/ctree.h fs/btrfs/defrag.c+106 -1161 reply

Reviews trailers per patch

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

Read the v2 thread

Cover letter [PATCH v2 0/8] btrfs: some fixes and cleanups around btrfs_cow_block()

From: Filipe Manana <[email protected]>

This adds some missing error handling for highly unexpected but critical conditions when COWing a tree block, some cleanups and moving some defrag specific code out of ctree.c into defrag.c. More details on the changelogs.

V2: Fix compilation error on big endian systems (patch 7/8).
Use transaction abort in patches 1/8 and 3/8.

Filipe Manana (8):
btrfs: error out when COWing block using a stale transaction
btrfs: error when COWing block from a root that is being deleted
btrfs: error out when reallocating block for defrag using a stale transaction
btrfs: remove noinline attribute from btrfs_cow_block()
btrfs: use round_down() to align block offset at btrfs_cow_block()
btrfs: rename and export __btrfs_cow_block()
btrfs: export comp_keys() from ctree.c as btrfs_comp_keys()
btrfs: move btrfs_realloc_node() from ctree.c into defrag.c

 fs/btrfs/ctree.c  | 198 ++++++++++------------------------------------
 fs/btrfs/ctree.h  |  42 +++++++++-
 fs/btrfs/defrag.c | 106 +++++++++++++++++++++++++
 3 files changed, 185 insertions(+), 161 deletions(-)
Signature · 1 line
2.40.1