/illumos-gate/usr/src/uts/common/fs/zfs/ |
H A D | zfs_vfsops.c | 159 zfsvfs_t *zfsvfs = vfsp->vfs_data; in zfs_sync() local 162 ZFS_ENTER(zfsvfs); in zfs_sync() 163 dp = dmu_objset_pool(zfsvfs->z_os); in zfs_sync() 170 ZFS_EXIT(zfsvfs); in zfs_sync() 174 if (zfsvfs->z_log != NULL) in zfs_sync() 175 zil_commit(zfsvfs->z_log, 0); in zfs_sync() 177 ZFS_EXIT(zfsvfs); in zfs_sync() 258 zfsvfs_t *zfsvfs = arg; in atime_changed_cb() local 261 zfsvfs->z_atime = TRUE; in atime_changed_cb() 262 vfs_clearmntopt(zfsvfs->z_vfs, MNTOPT_NOATIME); in atime_changed_cb() [all …]
|
H A D | zfs_fuid.c | 195 zfs_fuid_init(zfsvfs_t *zfsvfs) in zfs_fuid_init() argument 197 rw_enter(&zfsvfs->z_fuid_lock, RW_WRITER); in zfs_fuid_init() 199 if (zfsvfs->z_fuid_loaded) { in zfs_fuid_init() 200 rw_exit(&zfsvfs->z_fuid_lock); in zfs_fuid_init() 204 zfs_fuid_avl_tree_create(&zfsvfs->z_fuid_idx, &zfsvfs->z_fuid_domain); in zfs_fuid_init() 206 (void) zap_lookup(zfsvfs->z_os, MASTER_NODE_OBJ, in zfs_fuid_init() 207 ZFS_FUID_TABLES, 8, 1, &zfsvfs->z_fuid_obj); in zfs_fuid_init() 208 if (zfsvfs->z_fuid_obj != 0) { in zfs_fuid_init() 209 zfsvfs->z_fuid_size = zfs_fuid_table_load(zfsvfs->z_os, in zfs_fuid_init() 210 zfsvfs->z_fuid_obj, &zfsvfs->z_fuid_idx, in zfs_fuid_init() [all …]
|
H A D | zfs_dir.c | 68 zfs_match_find(zfsvfs_t *zfsvfs, znode_t *dzp, char *name, matchtype_t mt, in zfs_match_find() argument 73 if (zfsvfs->z_norm) { in zfs_match_find() 87 error = zap_lookup_norm(zfsvfs->z_os, dzp->z_id, name, 8, 1, in zfs_match_find() 92 error = zap_lookup(zfsvfs->z_os, dzp->z_id, name, 8, 1, zoid); in zfs_match_find() 141 zfsvfs_t *zfsvfs = dzp->z_zfsvfs; in zfs_dirent_lock() local 188 if (zfsvfs->z_norm != 0) { in zfs_dirent_lock() 196 if ((zfsvfs->z_case == ZFS_CASE_INSENSITIVE && in zfs_dirent_lock() 198 (zfsvfs->z_case == ZFS_CASE_MIXED && !(flag & ZCILOOK))) { in zfs_dirent_lock() 213 update = !zfsvfs->z_norm || in zfs_dirent_lock() 214 (zfsvfs->z_case == ZFS_CASE_MIXED && in zfs_dirent_lock() [all …]
|
H A D | zfs_znode.c | 279 zfsvfs_t *zfsvfs; in zfs_znode_move() local 290 zfsvfs = ozp->z_zfsvfs; in zfs_znode_move() 291 if (!POINTER_IS_VALID(zfsvfs)) { in zfs_znode_move() 303 if (zfsvfs != ozp->z_zfsvfs) { in zfs_znode_move() 315 rrm_enter(&zfsvfs->z_teardown_lock, RW_READER, FTAG); in zfs_znode_move() 316 if (zfsvfs->z_unmounted) { in zfs_znode_move() 317 ZFS_EXIT(zfsvfs); in zfs_znode_move() 324 mutex_enter(&zfsvfs->z_znodes_lock); in zfs_znode_move() 329 if (zfsvfs != ozp->z_zfsvfs) { in zfs_znode_move() 330 mutex_exit(&zfsvfs->z_znodes_lock); in zfs_znode_move() [all …]
|
H A D | zfs_vnops.c | 198 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_open() local 200 ZFS_ENTER(zfsvfs); in zfs_open() 205 ZFS_EXIT(zfsvfs); in zfs_open() 213 ZFS_EXIT(zfsvfs); in zfs_open() 222 ZFS_EXIT(zfsvfs); in zfs_open() 232 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_close() local 240 ZFS_ENTER(zfsvfs); in zfs_close() 252 ZFS_EXIT(zfsvfs); in zfs_close() 362 zfsvfs_t *zfsvfs; in zfs_ioctl() local 428 zfsvfs = zp->z_zfsvfs; in zfs_ioctl() [all …]
|
H A D | zfs_ctldir.c | 204 zfsvfs_t *zfsvfs = vp->v_vfsp->vfs_data; in zfsctl_root_inode_cb() local 211 return (zfsvfs->z_shares_dir); in zfsctl_root_inode_cb() 221 zfsctl_create(zfsvfs_t *zfsvfs) in zfsctl_create() argument 227 ASSERT(zfsvfs->z_ctldir == NULL); in zfsctl_create() 229 vp = gfs_root_create(sizeof (zfsctl_node_t), zfsvfs->z_vfs, in zfsctl_create() 235 VERIFY(VFS_ROOT(zfsvfs->z_vfs, &rvp) == 0); in zfsctl_create() 236 VERIFY(0 == sa_lookup(VTOZ(rvp)->z_sa_hdl, SA_ZPL_CRTIME(zfsvfs), in zfsctl_create() 248 zfsvfs->z_ctldir = vp; in zfsctl_create() 257 zfsctl_destroy(zfsvfs_t *zfsvfs) in zfsctl_destroy() argument 259 VN_RELE(zfsvfs->z_ctldir); in zfsctl_destroy() [all …]
|
H A D | zfs_sa.c | 126 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_sa_get_scanstamp() local 132 if (sa_lookup(zp->z_sa_hdl, SA_ZPL_SCANSTAMP(zfsvfs), in zfs_sa_get_scanstamp() 160 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_sa_set_scanstamp() local 166 VERIFY(0 == sa_update(zp->z_sa_hdl, SA_ZPL_SCANSTAMP(zfsvfs), in zfs_sa_set_scanstamp() 183 VERIFY(0 == sa_update(zp->z_sa_hdl, SA_ZPL_FLAGS(zfsvfs), in zfs_sa_set_scanstamp() 201 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_sa_upgrade() local 238 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_MTIME(zfsvfs), NULL, &mtime, 16); in zfs_sa_upgrade() 239 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_CTIME(zfsvfs), NULL, &ctime, 16); in zfs_sa_upgrade() 240 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_CRTIME(zfsvfs), NULL, &crtime, 16); in zfs_sa_upgrade() 241 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_MODE(zfsvfs), NULL, &mode, 8); in zfs_sa_upgrade() [all …]
|
H A D | zfs_replay.c | 278 zfsvfs_t *zfsvfs = arg1; in zfs_replay_create_acl() local 316 if ((error = zfs_zget(zfsvfs, lr->lr_doid, &dzp)) != 0) in zfs_replay_create_acl() 338 error = dnode_try_claim(zfsvfs->z_os, objid, dnodesize >> DNODE_SHIFT); in zfs_replay_create_acl() 349 zfsvfs->z_fuid_replay = zfs_replay_fuids(fuidstart, in zfs_replay_create_acl() 365 if (zfsvfs->z_fuid_replay == NULL) { in zfs_replay_create_acl() 368 zfsvfs->z_fuid_replay = in zfs_replay_create_acl() 381 zfsvfs->z_fuid_replay = zfs_replay_fuids(fuidstart, in zfs_replay_create_acl() 396 if (zfsvfs->z_fuid_replay == NULL) { in zfs_replay_create_acl() 399 zfsvfs->z_fuid_replay = in zfs_replay_create_acl() 417 if (zfsvfs->z_fuid_replay) in zfs_replay_create_acl() [all …]
|
H A D | zfs_acl.c | 381 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_acl_znode_info() local 388 if ((error = sa_size(zp->z_sa_hdl, SA_ZPL_DACL_ACES(zfsvfs), in zfs_acl_znode_info() 392 if ((error = sa_lookup(zp->z_sa_hdl, SA_ZPL_DACL_COUNT(zfsvfs), in zfs_acl_znode_info() 397 if ((error = sa_lookup(zp->z_sa_hdl, SA_ZPL_ZNODE_ACL(zfsvfs), in zfs_acl_znode_info() 668 zfs_copy_ace_2_fuid(zfsvfs_t *zfsvfs, vtype_t obj_type, zfs_acl_t *aclp, in zfs_copy_ace_2_fuid() argument 686 aceptr->z_fuid = zfs_fuid_create(zfsvfs, acep->a_who, in zfs_copy_ace_2_fuid() 730 zfs_copy_fuid_2_ace(zfsvfs_t *zfsvfs, zfs_acl_t *aclp, cred_t *cr, in zfs_copy_fuid_2_ace() argument 775 acep->a_who = zfs_fuid_map_id(zfsvfs, who, in zfs_copy_fuid_2_ace() 1199 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in zfs_aclset_common() local 1223 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_MODE(zfsvfs), NULL, in zfs_aclset_common() [all …]
|
H A D | sa.c | 1512 zfsvfs_t *zfsvfs = zp->z_zfsvfs; in sa_add_projid() local 1536 err = sa_lookup_locked(hdl, SA_ZPL_PROJID(zfsvfs), &projid, in sa_add_projid() 1546 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_MODE(zfsvfs), NULL, in sa_add_projid() 1548 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_GEN(zfsvfs), NULL, in sa_add_projid() 1550 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_UID(zfsvfs), NULL, in sa_add_projid() 1552 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_GID(zfsvfs), NULL, in sa_add_projid() 1554 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_PARENT(zfsvfs), NULL, in sa_add_projid() 1556 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_ATIME(zfsvfs), NULL, in sa_add_projid() 1558 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_MTIME(zfsvfs), NULL, in sa_add_projid() 1560 SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_CTIME(zfsvfs), NULL, in sa_add_projid() [all …]
|
H A D | zfs_ioctl.c | 1557 zfsvfs_rele(zfsvfs_t *zfsvfs, void *tag) in zfsvfs_rele() argument 1559 rrm_exit(&zfsvfs->z_teardown_lock, tag); in zfsvfs_rele() 1561 if (zfsvfs->z_vfs) { in zfsvfs_rele() 1562 VFS_RELE(zfsvfs->z_vfs); in zfsvfs_rele() 1564 dmu_objset_disown(zfsvfs->z_os, B_TRUE, zfsvfs); in zfsvfs_rele() 1565 zfsvfs_free(zfsvfs); in zfsvfs_rele() 2467 zfsvfs_t *zfsvfs; in zfs_prop_set_userquota() local 2492 err = zfsvfs_hold(dsname, FTAG, &zfsvfs, B_FALSE); in zfs_prop_set_userquota() 2494 err = zfs_set_userquota(zfsvfs, type, domain, rid, quota); in zfs_prop_set_userquota() 2495 zfsvfs_rele(zfsvfs, FTAG); in zfs_prop_set_userquota() [all …]
|
H A D | zcp_get.c | 698 zfsvfs_t *zfsvfs; in zcp_get_userquota_prop() local 713 zfsvfs = kmem_zalloc(sizeof (zfsvfs_t), KM_SLEEP); in zcp_get_userquota_prop() 714 error = zfsvfs_create_impl(&zfvp, zfsvfs, os); in zcp_get_userquota_prop()
|
/illumos-gate/usr/src/uts/common/fs/zfs/sys/ |
H A D | zfs_vfsops.h | 41 typedef struct zfsvfs zfsvfs_t; 44 struct zfsvfs { struct 148 extern int zfs_suspend_fs(zfsvfs_t *zfsvfs); 149 extern int zfs_resume_fs(zfsvfs_t *zfsvfs, struct dsl_dataset *ds); 150 extern int zfs_userspace_one(zfsvfs_t *zfsvfs, zfs_userquota_prop_t type, 152 extern int zfs_userspace_many(zfsvfs_t *zfsvfs, zfs_userquota_prop_t type, 154 extern int zfs_set_userquota(zfsvfs_t *zfsvfs, zfs_userquota_prop_t type, 156 extern boolean_t zfs_id_overblockquota(zfsvfs_t *zfsvfs, uint64_t usedobj, 158 extern boolean_t zfs_id_overobjquota(zfsvfs_t *zfsvfs, uint64_t usedobj, 160 extern boolean_t zfs_id_overquota(zfsvfs_t *zfsvfs, uint64_t usedobj, [all …]
|
H A D | zfs_znode.h | 186 struct zfsvfs *z_zfsvfs; 249 #define ZFS_ENTER(zfsvfs) \ argument 251 rrm_enter_read(&(zfsvfs)->z_teardown_lock, FTAG); \ 252 if ((zfsvfs)->z_unmounted) { \ 253 ZFS_EXIT(zfsvfs); \ 259 #define ZFS_EXIT(zfsvfs) rrm_exit(&(zfsvfs)->z_teardown_lock, FTAG) argument 272 #define ZFS_OBJ_MUTEX(zfsvfs, obj_num) \ argument 273 (&(zfsvfs)->z_hold_mtx[ZFS_OBJ_HASH(obj_num)]) 274 #define ZFS_OBJ_HOLD_ENTER(zfsvfs, obj_num) \ argument 275 mutex_enter(ZFS_OBJ_MUTEX((zfsvfs), (obj_num))) [all …]
|
H A D | zfs_dir.h | 65 extern void zfs_unlinked_drain(zfsvfs_t *zfsvfs); 66 extern void zfs_unlinked_drain_stop_wait(zfsvfs_t *zfsvfs);
|
H A D | zfs_acl.h | 203 struct zfsvfs; 209 boolean_t zfs_acl_ids_overquota(struct zfsvfs *, zfs_acl_ids_t *, uint64_t); 226 int zfs_vsec_2_aclp(struct zfsvfs *, vtype_t, vsecattr_t *, cred_t *,
|
H A D | zfs_fuid.h | 121 extern const char *zfs_fuid_find_by_idx(zfsvfs_t *zfsvfs, uint32_t idx); 122 extern void zfs_fuid_txhold(zfsvfs_t *zfsvfs, dmu_tx_t *tx);
|
H A D | zfs_ioctl.h | 491 struct zfsvfs; 506 extern int getzfsvfs_impl(struct objset *, struct zfsvfs **); 507 extern int getzfsvfs(const char *, struct zfsvfs **);
|