CVE-2026-80897: netfs: release readahead folios on iterator preparation failure
In the Linux kernel, the following vulnerability has been resolved:
netfs: release readahead folios on iterator preparation failure
netfspreparereaditerator() batches readahead folios in putbatch so that the folio references can be dropped after the I/O iterator has been prepared.
If rollingbufferloadfromra() fails after earlier folios have been batched, the function returns immediately and leaves those references held. Release the batch before returning the error.
Affected Software
Event History
Frequently Asked Questions
What is the impact if the failure path is triggered?
Earlier readahead folios already placed in the batch retain their references when iterator preparation fails. This can result in folio reference leaks.
Under what condition does the leak occur?
The issue occurs when rolling_buffer_load_from_ra() fails after netfs_prepare_read_iterator() has already batched one or more readahead folios.
What change resolves the issue?
The fix releases the accumulated folio batch before netfs_prepare_read_iterator() returns the error.