CVE-2022-50766

btrfs: set generation before calling btrfs_clean_tree_block in btrfs_init_new_buffer

N/A
Published: December 24, 2025 at 01:05 PM UTC
Updated: June 17, 2026 at 05:24 AM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
N/A
Exploit prediction
EPSS 0.2%

Description

In the Linux kernel, the following vulnerability has been resolved: btrfs: set generation before calling btrfs_clean_tree_block in btrfs_init_new_buffer syzbot is reporting uninit-value in btrfs_clean_tree_block() [1], for commit bc877d285ca3dba2 ("btrfs: Deduplicate extent_buffer init code") missed that btrfs_set_header_generation() in btrfs_init_new_buffer() must not be moved to after clean_tree_block() because clean_tree_block() is calling btrfs_header_generation() since commit 55c69072d6bd5be1 ("Btrfs: Fix extent_buffer usage when nodesize != leafsize"). Since memzero_extent_buffer() will reset "struct btrfs_header" part, we can't move btrfs_set_header_generation() to before memzero_extent_buffer(). Just re-add btrfs_set_header_generation() before btrfs_clean_tree_block().

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

4.19 ≤ v < 5.15.754.19 ≤ v < 5.19.174.19 ≤ v < 6.0.34.19 ≤ v < 6.14.19bc877d285ca3dba24c52406946a4a69847cc7422
Vendor states this is fixed in 0a408c6212c16b9a2a1141d3c531247582ef8101 (fixed)
Vendor states this is fixed in 89bc41c92d10b905c60f6ec13c9ef664a3555c54 (fixed)
Vendor states this is fixed in a687c2890fe4a2acaac6941fa4097a1264d8f3eb (fixed)
Vendor states this is fixed in cbddcc4fa3443fe8cfb2ff8e210deb1f6a0eea38 (fixed)
Vendor states this is fixed in 4.19 (unaffected)
Vendor states this is fixed in 5.15.75 (unaffected)
Vendor states this is fixed in 5.19.17 (unaffected)
Vendor states this is fixed in 6.0.3 (unaffected)
Vendor states this is fixed in 6.1 (unaffected)

Remediation

No guide yet

No remediation guidance has been written for this CVE yet, and no fixed version or vendor advisory is recorded against it.

Quick Info

StatusDEFERRED

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card