Re: [PATCH v5] btrfs: retry verity reads for not-uptodate Merkle folios

David Sterba <[email protected]>
Newsgroups org.kernel.vger.linux-btrfs,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
On Mon, Aug 17, 2026 at 01:48:37PM +0800, Yichong Chen wrote:
> btrfs_read_merkle_tree_page() can find a folio in the mapping that is not
> uptodate.  After taking the folio lock, the current code treats that state
> as a read error and returns -EIO.
> 
> That can make a previous transient read failure sticky.  If the failed read
> left a not-uptodate folio in the mapping, later callers find that folio and
> fail instead of retrying the read.
> 
> Keep the existing page-cache insertion and locking order, but retry the
> Merkle item read when a not-uptodate folio is found in the mapping.  Also
> unlock the folio when read_key_bytes() fails so that a later caller can
> lock it and retry the read.
> 
> Reviewed-by: Boris Burkov <[email protected]>
> Signed-off-by: Yichong Chen <[email protected]>
> ---
> v5:
> - Drop the Fixes tag, as Matthew pointed out that 06ed09351b67 did not
>   introduce the original !uptodate-page handling.

This was merged as commit 8cc569696dac51 ("btrfs: retry verity reads for
not-uptodate Merkle folios")
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.