Date: Thu, 26 Mar 2026 15:08:18 +0000 From: Alan Somers <asomers@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Cc: Gleb Popov <arrowd@FreeBSD.org> Subject: git: 1ebccc3b0f68 - stable/15 - vfs_cluster.c: Do not propagate VOP_BMAP errors to the caller Message-ID: <69c54be2.21796.6df3eaca@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch stable/15 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=1ebccc3b0f68dccb2447a6f251e6fa409cb3b2eb commit 1ebccc3b0f68dccb2447a6f251e6fa409cb3b2eb Author: Gleb Popov <arrowd@FreeBSD.org> AuthorDate: 2025-07-11 07:42:09 +0000 Commit: Alan Somers <asomers@FreeBSD.org> CommitDate: 2026-03-26 15:02:16 +0000 vfs_cluster.c: Do not propagate VOP_BMAP errors to the caller The code that makes this VOP_BMAP call tries to perform a read-ahead I/O operation. Failing to do that for any reason isn't fatal for `cluster_read()`, because we still can return some data to the caller. This change is consistent with other places within `cluster_read()`, where error returned by VOP_BMAP is not returned to the caller - see the `if (nblks > 1)` block above the changed lines and `if (reqbp)` at the end of the function. PR: 264196 Approved by: markj, kib Differential Revision: https://reviews.freebsd.org/D51254 (cherry picked from commit 62aef3f73f38db9fb68bffc12cc8900fecd58f0e) --- sys/kern/vfs_cluster.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/kern/vfs_cluster.c b/sys/kern/vfs_cluster.c index 2e397b8e9e8f..b674313993c4 100644 --- a/sys/kern/vfs_cluster.c +++ b/sys/kern/vfs_cluster.c @@ -260,8 +260,10 @@ cluster_read(struct vnode *vp, u_quad_t filesize, daddr_t lblkno, long size, */ while (lblkno < (origblkno + maxra)) { error = VOP_BMAP(vp, lblkno, NULL, &blkno, &ncontig, NULL); - if (error) + if (error) { + error = 0; break; + } if (blkno == -1) break;home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69c54be2.21796.6df3eaca>
