diff options
author | kib <kib@FreeBSD.org> | 2014-08-04 01:12:49 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2014-08-04 01:12:49 +0000 |
commit | 00b893a5990df43ad05de3e6c2b27136695f27c3 (patch) | |
tree | 0e55f3b8cd8a38cfc289615b0e80d9d3f0ee27ea /sys | |
parent | cec08c72943984a080e6b4dd91ddb8d27f8adf1b (diff) | |
download | FreeBSD-src-00b893a5990df43ad05de3e6c2b27136695f27c3.zip FreeBSD-src-00b893a5990df43ad05de3e6c2b27136695f27c3.tar.gz |
MFC r269189:
Initialize zfs vnode v_hash when the vnode is allocated.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c | 2 | ||||
-rw-r--r-- | sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c | 5 |
2 files changed, 3 insertions, 4 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c index 0c3ffdf..433f13c 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c @@ -2076,8 +2076,6 @@ zfs_vget(vfs_t *vfsp, ino_t ino, int flags, vnode_t **vpp) err = vn_lock(*vpp, flags); if (err != 0) *vpp = NULL; - else - (*vpp)->v_hash = ino; return (err); } diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c index ac55996..c8f86b8 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c @@ -1228,9 +1228,10 @@ again: vnode_t *vp = ZTOV(zp); err = insmntque(vp, zfsvfs->z_vfs); - if (err == 0) + if (err == 0) { + vp->v_hash = obj_num; VOP_UNLOCK(vp, 0); - else { + } else { zp->z_vnode = NULL; zfs_znode_dmu_fini(zp); zfs_znode_free(zp); |