/freebsd/lib/libbe/ |
H A D | be_access.c | 51 be_mountcheck_cb(zfs_handle_t *zfs_hdl, void *data) in be_mountcheck_cb() argument 59 if (!zfs_is_mounted(zfs_hdl, &mountpoint)) in be_mountcheck_cb() 62 info->name = strdup(zfs_get_name(zfs_hdl)); in be_mountcheck_cb() 76 be_mount_iter(zfs_handle_t *zfs_hdl, void *data) in be_mount_iter() argument 85 if (zfs_is_mounted(zfs_hdl, &mountpoint)) { in be_mount_iter() 98 if (zfs_prop_get_int(zfs_hdl, ZFS_PROP_CANMOUNT) == in be_mount_iter() 102 if (zfs_prop_get(zfs_hdl, ZFS_PROP_MOUNTPOINT, zfs_mnt, in be_mount_iter() 120 if ((err = zfs_mount_at(zfs_hdl, NULL, info->mntflags, tmp)) != 0) { in be_mount_iter() 142 err = zfs_iter_filesystems(zfs_hdl, be_mount_iter, info); in be_mount_iter() 149 be_umount_iter(zfs_handle_t *zfs_hdl, void *data) in be_umount_iter() argument [all …]
|
H A D | be_info.c | 159 prop_list_builder_cb(zfs_handle_t *zfs_hdl, void *data_p) in prop_list_builder_cb() argument 181 dataset = zfs_get_name(zfs_hdl); in prop_list_builder_cb() 191 mounted = zfs_is_mounted(zfs_hdl, &mountpoint); in prop_list_builder_cb() 196 if (zfs_prop_get(zfs_hdl, ZFS_PROP_MOUNTPOINT, buf, 512, in prop_list_builder_cb() 200 if (zfs_prop_get(zfs_hdl, ZFS_PROP_ORIGIN, buf, 512, in prop_list_builder_cb() 204 if (zfs_prop_get(zfs_hdl, ZFS_PROP_CREATION, buf, 512, in prop_list_builder_cb() 211 if (zfs_prop_get(zfs_hdl, ZFS_PROP_USED, buf, 512, in prop_list_builder_cb() 215 if (zfs_prop_get(zfs_hdl, ZFS_PROP_USEDDS, buf, 512, in prop_list_builder_cb() 219 if (zfs_prop_get(zfs_hdl, ZFS_PROP_USEDSNAP, buf, 512, in prop_list_builder_cb() 223 if (zfs_prop_get(zfs_hdl, ZFS_PROP_USEDREFRESERV, buf, 512, in prop_list_builder_cb() [all …]
|
H A D | be.c | 221 be_should_promote_clones(zfs_handle_t *zfs_hdl, struct be_destroy_data *bdd) in be_should_promote_clones() argument 225 if (zfs_get_type(zfs_hdl) != ZFS_TYPE_SNAPSHOT) in be_should_promote_clones() 238 atpos = strchr(zfs_get_name(zfs_hdl), '@'); in be_should_promote_clones() 249 be_dependent_clone_cb(zfs_handle_t *zfs_hdl, void *data) in be_dependent_clone_cb() argument 263 if (be_should_promote_clones(zfs_hdl, bdd) && in be_dependent_clone_cb() 264 (nvl = zfs_get_clones_nvl(zfs_hdl)) != NULL) { in be_dependent_clone_cb() 318 zfs_close(zfs_hdl); in be_dependent_clone_cb() 327 be_promote_dependent_clones(zfs_handle_t *zfs_hdl, struct be_destroy_data *bdd) in be_promote_dependent_clones() argument 333 snprintf(bdd->target_name, BE_MAXPATHLEN, "%s/", zfs_get_name(zfs_hdl)); in be_promote_dependent_clones() 334 err = zfs_iter_dependents(zfs_hdl, true, be_dependent_clone_cb, bdd); in be_promote_dependent_clones() [all …]
|
/freebsd/sys/contrib/openzfs/lib/libzfs/ |
H A D | libzfs_crypto.c | 1296 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1305 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1317 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1322 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1339 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1352 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1370 ret = get_key_material(zhp->zfs_hdl, B_FALSE, B_FALSE, keyformat, in zfs_crypto_load_key() 1377 ret = derive_key(zhp->zfs_hdl, keyformat, iters, key_material, salt, in zfs_crypto_load_key() 1389 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() 1393 zfs_error_aux(zhp->zfs_hdl, dgettext(TEXT_DOMAIN, in zfs_crypto_load_key() [all …]
|
H A D | libzfs_diff.c | 77 error = zfs_ioctl(di->zhp->zfs_hdl, ZFS_IOC_OBJ_TO_STATS, &zc); in get_stats_for_obj() 286 zfs_error_aux(di->zhp->zfs_hdl, "%s", zfs_strerror(di->zerr)); in write_inuse_diffs_one() 287 zfs_error(di->zhp->zfs_hdl, di->zerr, di->errbuf); in write_inuse_diffs_one() 300 zfs_error_aux(di->zhp->zfs_hdl, in write_inuse_diffs_one() 302 zfs_error(di->zhp->zfs_hdl, di->zerr, di->errbuf); in write_inuse_diffs_one() 400 libzfs_handle_t *lhdl = di->zhp->zfs_hdl; in write_free_diffs() 505 libzfs_handle_t *hdl = di->zhp->zfs_hdl; in make_temp_snapshot() 551 libzfs_handle_t *hdl = di->zhp->zfs_hdl; in get_snapshot_names() 614 di->ds = zfs_alloc(di->zhp->zfs_hdl, tdslen + 1); in get_snapshot_names() 668 mounted = is_mounted(di->zhp->zfs_hdl, dsnm, mntpt); in get_mountpoint() [all …]
|
H A D | libzfs_iter.c | 53 zfs_handle_t *clone = zfs_open(zhp->zfs_hdl, nvpair_name(pair), in zfs_iter_clones() 74 rc = zfs_ioctl(zhp->zfs_hdl, arg, zc); in zfs_do_list_ioctl() 80 zcmd_expand_dst_nvlist(zhp->zfs_hdl, zc); in zfs_do_list_ioctl() 93 rc = zfs_standard_error(zhp->zfs_hdl, errno, in zfs_do_list_ioctl() 122 zcmd_alloc_dst_nvlist(zhp->zfs_hdl, &zc, 0); in zfs_iter_filesystems_v2() 132 nzhp = make_dataset_handle_zc(zhp->zfs_hdl, &zc); in zfs_iter_filesystems_v2() 175 zcmd_alloc_dst_nvlist(zhp->zfs_hdl, &zc, 0); in zfs_iter_snapshots_v2() 188 zcmd_write_src_nvlist(zhp->zfs_hdl, &zc, range_nvl); in zfs_iter_snapshots_v2() 196 nzhp = make_dataset_handle_zc(zhp->zfs_hdl, &zc); in zfs_iter_snapshots_v2() 304 node = zfs_alloc(zhp->zfs_hdl, sizeof (zfs_node_t)); in zfs_sort_snaps() [all …]
|
H A D | libzfs_dataset.c | 238 libzfs_handle_t *hdl = zhp->zfs_hdl; in process_user_props() 266 libzfs_handle_t *hdl = zhp->zfs_hdl; in zpool_add_handle() 280 libzfs_handle_t *hdl = zhp->zfs_hdl; in zpool_find_handle() 302 pool_name = zfs_alloc(zhp->zfs_hdl, len); in zpool_handle() 332 libzfs_handle_t *hdl = zhp->zfs_hdl; in get_stats_ioctl() 351 libzfs_handle_t *hdl = zhp->zfs_hdl; in get_recvd_props_ioctl() 369 err = zcmd_read_dst_nvlist(zhp->zfs_hdl, &zc, &recvdprops); in get_recvd_props_ioctl() 387 if (zcmd_read_dst_nvlist(zhp->zfs_hdl, zc, &allprops) != 0) { in put_stats_zhdl() 415 zcmd_alloc_dst_nvlist(zhp->zfs_hdl, &zc, 0); in get_stats() 487 zhp->zfs_hdl in make_dataset_handle() [all...] |
H A D | libzfs_sendrecv.c | 513 fromsnap_txg = get_snap_txg(zhp->zfs_hdl, zhp->zfs_name, sd->fromsnap); in send_iterate_fs() 517 tosnap_txg = get_snap_txg(zhp->zfs_hdl, zhp->zfs_name, sd->tosnap); in send_iterate_fs() 559 zfs_handle_t *origin = zfs_open(zhp->zfs_hdl, in send_iterate_fs() 633 snap = zfs_open(zhp->zfs_hdl, snapname, ZFS_TYPE_SNAPSHOT); in send_iterate_fs() 649 zhp->zfs_hdl->libzfs_max_nvlist) { in send_iterate_fs() 769 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_send_space() 815 libzfs_handle_t *hdl = zhp->zfs_hdl; in dump_ioctl() 834 if (zfs_ioctl(zhp->zfs_hdl, ZFS_IOC_SEND, &zc) != 0) { in dump_ioctl() 923 if (zfs_ioctl(zhp->zfs_hdl, ZFS_IOC_SEND_PROGRESS, &zc) != 0) in zfs_send_progress() 1283 if (send_progress_thread_exit(zhp->zfs_hdl, tid, &oldmask)) in dump_snapshot() [all …]
|
H A D | libzfs_mount.c | 200 is_mounted(libzfs_handle_t *zfs_hdl, const char *special, char **where) in is_mounted() argument 204 if (libzfs_mnttab_find(zfs_hdl, special, &entry) != 0) in is_mounted() 208 *where = zfs_strdup(zfs_hdl, entry.mnt_mountp); in is_mounted() 216 return (is_mounted(zhp->zfs_hdl, zfs_get_name(zhp), where)); in zfs_is_mounted() 366 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_mount_at() 574 return (zfs_error_fmt(zhp->zfs_hdl, libzfs_err, in unmount_one() 591 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_unmount() 740 return (zfs_error_fmt(zhp->zfs_hdl, in zfs_share() 807 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_unshare() 897 newhandles = zfs_realloc(zhp->zfs_hdl, in libzfs_add_handle()
|
H A D | libzfs_changelist.c | 646 clp = zfs_alloc(zhp->zfs_hdl, sizeof (prop_changelist_t)); in changelist_gather() 672 (void) zfs_error(zhp->zfs_hdl, EZFS_NOMEM, "internal error"); in changelist_gather() 683 (void) zfs_error(zhp->zfs_hdl, EZFS_NOMEM, "internal error"); in changelist_gather() 750 if ((temp = zfs_open(zhp->zfs_hdl, zfs_get_name(zhp), in changelist_gather() 760 cn = zfs_alloc(zhp->zfs_hdl, sizeof (prop_changenode_t)); in changelist_gather()
|
H A D | libzfs_impl.h | 78 libzfs_handle_t *zfs_hdl; member
|
H A D | libzfs_util.c | 1142 return (zhp->zfs_hdl); in zfs_get_handle()
|
H A D | libzfs.abi | 2265 <var-decl name='zfs_hdl' type-id='b0382bb3' visibility='default'/>
|
/freebsd/sys/contrib/openzfs/cmd/zed/ |
H A D | zed_event.c | 53 zcp->zfs_hdl = libzfs_init(); in zed_event_init() 54 if (!zcp->zfs_hdl) { in zed_event_init() 68 zfs_agent_init(zcp->zfs_hdl); in zed_event_init() 101 if (zcp->zfs_hdl) { in zed_event_fini() 102 libzfs_fini(zcp->zfs_hdl); in zed_event_fini() 103 zcp->zfs_hdl = NULL; in zed_event_fini() 188 rv = zpool_events_next(zcp->zfs_hdl, &nvl, &n_dropped, in zed_event_seek() 218 if (zpool_events_seek(zcp->zfs_hdl, ZEVENT_SEEK_START, in zed_event_seek() 968 rv = zpool_events_next(zcp->zfs_hdl, &nvl, &n_dropped, ZEVENT_NONE, in zed_event_service()
|
H A D | zed_conf.h | 27 libzfs_handle_t *zfs_hdl; /* handle to libzfs */ member
|
/freebsd/sys/contrib/openzfs/lib/libzfs/os/linux/ |
H A D | libzfs_util_os.c | 174 return (zfs_error(di->zhp->zfs_hdl, EZFS_DIFF, di->errbuf)); in find_shares_object() 220 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_userns()
|
/freebsd/sys/contrib/openzfs/cmd/zed/agents/ |
H A D | zfs_agents.c | 391 zfs_agent_init(libzfs_handle_t *zfs_hdl) in zfs_agent_init() argument 395 g_zfs_hdl = zfs_hdl; in zfs_agent_init()
|
/freebsd/sys/contrib/openzfs/lib/libzfs/os/freebsd/ |
H A D | libzfs_compat.c | 282 libzfs_handle_t *hdl = zhp->zfs_hdl; in zfs_jail()
|