CVE-2026-143241

Source
https://cve.org/CVERecord?id=CVE-2026-143241
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-143241.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-143241
Downstream
Published
2026-12-03T09:20:53Z
Modified
2026-12-03T11:01:49Z
Summary
btrfs: zoned: don't wait for ordered extents in do_zone_finish()
Details

In the Linux kernel, the following vulnerability has been resolved:

btrfs: zoned: don't wait for ordered extents in do_zone_finish()

do_zone_finish() calls btrfs_wait_ordered_roots(), which holds fs_info->ordered_operations_mutex while waiting for writeback. It can be reached from writeback itself:

cow_file_range() -> btrfs_reserve_extent() -> find_free_extent() -> btrfs_zone_finish_one_bg() -> do_zone_finish()

If another task holds the mutex and waits for that writeback, this deadlocks.

In general, we want to ensure all writes in the block group to complete before finishing the zone, as relocation does. However, the current callers do not need the wait (or cannot wait) in do_zone_finish():

  • Relocation already waits for reservations and ordered extents itself before calling btrfs_zone_finish().
  • btrfs_delete_unused_bgs() checks that ->reserved is zero and sets the block group read-only while holding groups_sem, so there can be no in-flight data write.
  • btrfs_zone_finish_one_bg() is called from the allocation path and cannot wait.

Dropping the wait is still safe. Once the block group is read-only, ->reserved can only drop, and for data it only drops after the ordered extent's I/O has completed. So if ->reserved is zero, no data write is left in flight. If it is non-zero, do_zone_finish() returns -EAGAIN, which all callers handle.

This makes btrfs_zone_finish_one_bg() fail with -EAGAIN when it races with an allocation in the selected block group.

Database specific
{
    "cna_assigner":  "Linux",
    "osv_generated_from":  "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/143xxx/CVE-2026-143241.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
393f646e34c18b85d0f41272bfcbd475ae3a0d34
Fixed
d87f8bd1c92559fbd945ba7a202d0013c6436372
Fixed
b9d98dbc30312db7eeb77f4ed46af9573f17bc93
Fixed
bd1e6c8aacf49c9198ebe0664cc292052e597a43
Fixed
bcad7df05237382237ad1517411721d839174009
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
8be240190e01934b2f2009a73b2967cc7f0c6344
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
f6ad412c647ac32e3ed2750b99c87c119daea9bb

Affected versions

v5.*
v5.18.18
v5.18.19
v5.19.10
v5.19.11
v5.19.12
v5.19.13
v5.19.14
v5.19.15
v5.19.16
v5.19.17
v5.19.2
v5.19.3
v5.19.4
v5.19.5
v5.19.6
v5.19.7
v5.19.8
v5.19.9

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-143241.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
5.18.18
Fixed
5.19
Type
ECOSYSTEM
Events
Introduced
5.19.2
Fixed
5.20
Type
ECOSYSTEM
Events
Introduced
6.0.0
Fixed
6.12.120
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.18.66
Type
ECOSYSTEM
Events
Introduced
6.19.0
Fixed
7.3.7

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-143241.json"