CVE-2026-89834: f2fs: fix to migrate all curseg types during free_segment_range
In the Linux kernel, the following vulnerability has been resolved:
f2fs: fix to migrate all curseg types during freesegmentrange
In freesegmentrange(), the curseg evacuation loop only iterates up to NRCURSEGPERSISTTYPE (0..5), missing non-persistent in-memory curseg types such as CURSEGCOLDDATAPINNED and CURSEGALLDATAATGC.
Even though these in-memory curseg types are not saved in the on-disk checkpoint header, they still occupy active physical segments at runtime. If an active in-memory curseg happens to be allocated within the segment range being truncated during filesystem shrink, failing to evacuate it will cause subsequent writes to the curseg attempting out-of-bounds I/O on the truncated storage range.
Fix this by expanding the curseg evacuation loop upper bound to NRCURSEGTYPE to ensure all active curseg types are safely migrated out of the target range.
Affected Software
Event History
Frequently Asked Questions
Who is exposed to this issue?
Systems using the Linux kernel F2FS filesystem are exposed when an active non-persistent in-memory curseg type resides in the segment range being truncated during a filesystem shrink.
What operation triggers the vulnerable condition?
The condition occurs during filesystem shrink when free_segment_range() truncates a range containing an active in-memory curseg type that the evacuation loop does not migrate. Subsequent writes through that curseg can then attempt out-of-bounds I/O on the truncated range.
How can this be mitigated if the fix cannot be applied immediately?
The provided information identifies filesystem shrink and truncation of segment ranges as the triggering operation. Avoiding F2FS shrink operations prevents the described path from being exercised.
How can administrators determine whether they may have encountered this issue?
The described symptom is subsequent writes attempting out-of-bounds I/O after an F2FS filesystem shrink. The data does not provide a specific log message, detection command, or affected-version list.