From be697f43394b54f545bf141772e26962295745d8 Mon Sep 17 00:00:00 2001 From: Mateusz Guzik Date: Thu, 5 Jan 2023 19:56:40 +0100 Subject: [PATCH] FreeBSD: catch up to 1400077 Reviewed-by: Richard Yao Reviewed-by: Ryan Moeller Reviewed-by: Alexander Motin Signed-off-by: Mateusz Guzik Closes #14328 --- module/os/freebsd/zfs/zfs_znode.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/module/os/freebsd/zfs/zfs_znode.c b/module/os/freebsd/zfs/zfs_znode.c index bbc45fda85..1debc3ec3d 100644 --- a/module/os/freebsd/zfs/zfs_znode.c +++ b/module/os/freebsd/zfs/zfs_znode.c @@ -536,6 +536,9 @@ zfs_znode_alloc(zfsvfs_t *zfsvfs, dmu_buf_t *db, int blksz, * Acquire vnode lock before making it available to the world. */ vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); +#if __FreeBSD_version >= 1400077 + vn_set_state(vp, VSTATE_CONSTRUCTED); +#endif VN_LOCK_AREC(vp); if (vp->v_type != VFIFO) VN_LOCK_ASHARE(vp);