Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dist/uts/common/fs/zfs Enable NCLOOKUP f...
details: https://anonhg.NetBSD.org/src/rev/f22f6984a151
branches: trunk
changeset: 937817:f22f6984a151
user: hannken <hannken%NetBSD.org@localhost>
date: Thu Aug 27 09:57:33 2020 +0000
description:
Enable NCLOOKUP for ZFS.
diffstat:
external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vfsops.c | 4 ++--
external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c | 11 +++++++++--
external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c | 3 +++
3 files changed, 14 insertions(+), 4 deletions(-)
diffs (69 lines):
diff -r 92a7c3d025e6 -r f22f6984a151 external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vfsops.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vfsops.c Thu Aug 27 07:03:48 2020 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vfsops.c Thu Aug 27 09:57:33 2020 +0000
@@ -1517,7 +1517,7 @@
#endif
#ifdef __NetBSD__
vfsp->mnt_flag |= MNT_LOCAL;
- vfsp->mnt_iflag |= IMNT_MPSAFE;
+ vfsp->mnt_iflag |= IMNT_MPSAFE | IMNT_NCLOOKUP;
#endif
/*
@@ -2078,7 +2078,7 @@
vfsp->vfs_flag |= MNT_NFS4ACLS;
#endif
#ifdef __NetBSD__
- vfsp->mnt_iflag |= IMNT_MPSAFE;
+ vfsp->mnt_iflag |= IMNT_MPSAFE | IMNT_NCLOOKUP;
#endif
/*
diff -r 92a7c3d025e6 -r f22f6984a151 external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c Thu Aug 27 07:03:48 2020 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c Thu Aug 27 09:57:33 2020 +0000
@@ -1354,6 +1354,10 @@
newmode = zp->z_mode;
(void) sa_update(zp->z_sa_hdl, SA_ZPL_MODE(zfsvfs),
(void *)&newmode, sizeof (uint64_t), tx);
+#ifdef __NetBSD__
+ cache_enter_id(vp, zp->z_mode, zp->z_uid, zp->z_gid,
+ true);
+#endif
}
mutex_exit(&zp->z_acl_lock);
@@ -5645,8 +5649,11 @@
}
error = zfs_setattr(vp, (vattr_t *)&xvap, flags, cred, NULL);
- if (error == 0)
- VN_KNOTE(vp, NOTE_ATTRIB);
+ if (error)
+ return error;
+
+ VN_KNOTE(vp, NOTE_ATTRIB);
+ cache_enter_id(vp, zp->z_mode, zp->z_uid, zp->z_gid, true);
return error;
}
diff -r 92a7c3d025e6 -r f22f6984a151 external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c Thu Aug 27 07:03:48 2020 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_znode.c Thu Aug 27 09:57:33 2020 +0000
@@ -871,6 +871,7 @@
return (SET_ERROR(ENOENT));
}
ASSERT(zp == VTOZ(vp));
+ cache_enter_id(vp, zp->z_mode, zp->z_uid, zp->z_gid, true);
ZFS_OBJ_HOLD_EXIT(zfsvfs, obj_num);
@@ -891,6 +892,8 @@
zfs_mknode1(dzp, vap, tx, cr, flag, &zp, acl_ids, vp);
ASSERT(zp == VTOZ(vp));
+ cache_enter_id(vp, zp->z_mode, zp->z_uid, zp->z_gid, true);
+
*key_len = sizeof(zp->z_id);
*new_key = &zp->z_id;
Home |
Main Index |
Thread Index |
Old Index