[GIT PULL] Btrfs fixes for 6.12-rc6

From: David Sterba
Date: Fri Nov 01 2024 - 11:33:39 EST


Hi,

please pull a few more stability fixes. There's one patch adding export
of MIPS cmpxchg helper, used in the error propagation fix.

- fix error propagation from split bios to the original btrfs bio

- fix merging of adjacent extents (normal operation, defragmentation)

- fix potential use after free after freeing btrfs device structures

----------------------------------------------------------------
The following changes since commit 75f49c3dc7b7423d3734f2e4dabe3dac8d064338:

btrfs: fix passing 0 to ERR_PTR in btrfs_search_dir_index_item() (2024-10-22 16:10:55 +0200)

are available in the Git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux.git tags/for-6.12-rc5-tag

for you to fetch changes up to 77b0d113eec49a7390ff1a08ca1923e89f5f86c6:

btrfs: fix defrag not merging contiguous extents due to merged extent maps (2024-10-31 16:46:41 +0100)

----------------------------------------------------------------
David Sterba (1):
MIPS: export __cmpxchg_small()

Filipe Manana (2):
btrfs: fix extent map merging not happening for adjacent extents
btrfs: fix defrag not merging contiguous extents due to merged extent maps

Naohiro Aota (1):
btrfs: fix error propagation of split bios

Zhihao Cheng (1):
btrfs: fix use-after-free of block device file in __btrfs_free_extra_devids()

arch/mips/kernel/cmpxchg.c | 1 +
fs/btrfs/bio.c | 37 +++++++++++++------------------------
fs/btrfs/bio.h | 3 +++
fs/btrfs/defrag.c | 10 +++++-----
fs/btrfs/extent_map.c | 7 ++++++-
fs/btrfs/volumes.c | 1 +
6 files changed, 29 insertions(+), 30 deletions(-)