KernelScan.io

HIGH Introduced in 6.8

btrfs ExtentBuffer Race

CVE-2026-90260

CVSS 7.1 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H

KernelScan AI6.9MEDIUM

01

In the Linux kernel, the following vulnerability has been resolved: btrfs: zoned: don't clobber the extent buffer when zeroing it out On a zoned filesystem a freed-but-still-dirty tree block is written out as zeros (EXTENT_BUFFER_ZONED_ZEROOUT) only to keep the zone write pointer advancing. btree_csum_one_bio() implemented this by memzeroing the extent buffer's own folios before submission. That destroys the in-memory buffer while it may still be referenced. In particular btrfs_free_tree_block() can run on it afterwards and reads the header to add a delayed reference; once the header has been zeroed it frees bytenr 0 and corrupts the extent tree (the btrfs_header_bytenr(buf) != 0 ASSERT in btrfs_free_tree_block(), or an "unable to find ref" abort). It is flaky and reproduces under fsstress, e.g. generic/461 and generic/013. Write the zeros to disk from the shared zero page instead and leave the extent buffer content untouched, so any later reference - including the delayed reference from btrfs_free_tree_block() - still sees a valid header. end_bbio_meta_write() now clears writeback on the buffer's own folios, as the bio no longer carries them.

02

Engine v0.6.0

Risk summary

A race condition in btrfs zoned mode writeout destroys in-memory extent buffer content while other code paths may still reference it, leading to extent tree corruption. Any local user with write access to a zoned btrfs filesystem can trigger this through normal filesystem stress operations, though exploitation requires winning a timing-dependent race. Impact includes filesystem metadata corruption, kernel panics from assertion failures, and potential data loss.

Affectedfs/btrfs/disk-io.c, fs/btrfs/extent_io.c (btrfs zoned writeout)

Vulnerability analysis

On a btrfs filesystem using zoned mode, a freed-but-still-dirty tree block is written out as zeros solely to advance the zone write pointer. The writeout path achieved this by zeroing the extent buffer's own in-memory content before I/O submission, destroying the buffer while other code paths may still reference it. In particular, the tree-block freeing path can run concurrently and read the buffer's header to add a delayed reference; once the header has been zeroed it operates on bytenr 0 and corrupts the extent tree, triggering assertion failures or aborts. The fix writes zeros to disk from the shared zero page instead, leaving the extent buffer's content completely untouched so any later reference — including the delayed reference from the freeing path — still sees a valid header. This is reachable by any local user with write access to a btrfs zoned filesystem through ordinary file operations, but requires winning a race window that reproduces flakily under filesystem stress workloads.

03

BranchIntroducedFixed inPatch commit
6.126.86.12.114efa5084d0803
6.186.86.18.5292484ad014f2
7.26.87.2.698e3747587f9
mainline6.87.3db4b9eefc8ee

04

State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.

CIP treeState
cip/6.12Affected — no CIP fix yet (latest 6.12.112-cip33)