Date: Sun, 5 Oct 2025 21:22:00 GMT From: Mateusz Guzik <mjg@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: f16178e0bba8 - main - vfs foffset: drop weird commentary about offset protection Message-ID: <202510052122.595LM03K099136@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=f16178e0bba81c32b1f4fba310c7d0f2756aca85 commit f16178e0bba81c32b1f4fba310c7d0f2756aca85 Author: Mateusz Guzik <mjg@FreeBSD.org> AuthorDate: 2025-10-05 17:02:01 +0000 Commit: Mateusz Guzik <mjg@FreeBSD.org> CommitDate: 2025-10-05 21:21:10 +0000 vfs foffset: drop weird commentary about offset protection It is readily apparent the FOFFSET_LOCKED flag protects it because the read followed its use. It also does not matter who said how it was protected earlier. Reviewed by: kib, markj Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D52915 --- sys/kern/vfs_vnops.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index 3d4567b6ab1e..c2a669dc771a 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -864,10 +864,6 @@ foffset_lock(struct file *fp, int flags) FILE_V_FOFFSET_LOCK_WAITING); } - /* - * According to McKusick the vn lock was protecting f_offset here. - * It is now protected by the FOFFSET_LOCKED flag. - */ return (atomic_load_long(&fp->f_offset)); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202510052122.595LM03K099136>