Lines Matching refs:sh_zhp

703 	zfs_handle_t *sh_zhp;
715 if ((sh_zhp = zfs_fs_to_auto_share(zhp)) == NULL)
718 err = zfs_share_notify_impl(sh_zhp->zfs_hdl, sh_zhp->zfs_name, state);
719 if (zfs_is_cached(sh_zhp)) {
721 (void) zfs_update_share_handle(sh_zhp, state);
723 zfs_close(sh_zhp);
791 zfs_handle_t *sh_zhp;
809 sh_zhp = zfs_cache_get_quiet(hdl, sh_path, ZFS_TYPE_FILESYSTEM);
811 if (sh_zhp == NULL) {
821 zfs_close_uncached(sh_zhp);
826 == NULL) || strcmp(fsname, zfs_get_name(sh_zhp)) != 0) {
830 sh_path, zfs_get_name(sh_zhp), zfs_get_name(zhp));
831 zfs_close_uncached(sh_zhp);
835 zfs_close_uncached(sh_zhp);
1014 zfs_handle_t *sh_zhp;
1015 sh_zhp = zfs_fs_to_auto_share(zhp);
1016 if (sh_zhp != NULL) {
1018 zfs_prop_get_int(sh_zhp,
1023 zfs_close_uncached(sh_zhp);
1887 zfs_handle_t *sh_zhp = NULL;
1906 if ((sh_zhp = zfs_fs_to_auto_share(ds_zhp)) != NULL) {
1912 if (ZFS_GET_CACHE(sh_zhp) != NULL)
1913 zfs_cache_remove(ZFS_GET_CACHE(sh_zhp), sh_zhp);
1914 zfs_close(sh_zhp);
1915 sh_zhp = NULL;
1967 zfs_handle_t *sh_zhp = NULL;
1987 sh_zhp = zfs_cache_get_quiet(hdl, zfs_name, ZFS_TYPE_SHARE);
1988 if (sh_zhp != NULL) {
1990 * share object sh_zhp exists, update its properties.
1992 ret = zfssa_share_storage_write_s3_impl(sh_zhp,
2004 if (sh_zhp != NULL && !zfs_is_cached(sh_zhp))
2005 zfs_close(sh_zhp);
2337 zfs_handle_t *sh_zhp;
2348 sh_zhp = zfs_cache_get_quiet(zhp->zfs_hdl, sharename, ZFS_TYPE_SHARE);
2350 if (sh_zhp == NULL && zfs_matches_auto_share(zhp, sh_name,
2358 sh_zhp = zfs_cache_get_quiet(zhp->zfs_hdl, sharename,
2361 return (sh_zhp);
2373 zfs_handle_t *zhp, *sh_zhp;
2400 sh_zhp = zfs_share_open_byname(zhp, sh_name);
2402 if (sh_zhp != NULL) {
2403 (void) zfs_is_sharing_requested_protos(sh_zhp, protosp);
2404 zfs_close_uncached(sh_zhp);
2438 zfs_handle_t *zhp, *sh_zhp;
2460 sh_zhp = zfs_share_open_byname(zhp, sh_name);
2461 if (sh_zhp != NULL) {
2462 rc = zfssa_share_prop_get(sh_zhp, proto, propvalp);
2463 zfs_close_uncached(sh_zhp);
2507 zfs_handle_t *zhp, *sh_zhp;
2527 sh_zhp = zfs_share_open_byname(zhp, sh_name);
2528 if (sh_zhp != NULL) {
2529 rc = zfssa_share_prop_set(sh_zhp, proto, propval);
2530 zfs_close_uncached(sh_zhp);
2542 zfs_handle_t *sh_zhp;
2591 sh_zhp = zfs_share_open_byname(zhp, sh_name);
2594 if (sh_zhp == NULL)
2597 zhp = sh_zhp;
3903 zfs_handle_t *sh_zhp = NULL;
3955 sh_zhp = zfs_open_quiet(hdl, defaultshare,
3969 if (!persist || sh_zhp == NULL)
3973 (void) strlcpy(zc.zc_name, sh_zhp->zfs_name,
3977 zfs_close(sh_zhp);
4021 zfs_handle_t *sh_zhp;
4033 sh_zhp = zfs_cache_get_quiet(zhp->zfs_hdl, zc.zc_name,
4035 if (sh_zhp != NULL) {
4036 (void) zfs_update_share_handle(sh_zhp,
4038 zfs_close_uncached(sh_zhp);
4271 zfs_handle_t *sh_zhp;
4287 sh_zhp = zfs_cache_get_quiet(zhp->zfs_hdl, buf,
4289 if (sh_zhp != NULL) {
4294 zfs_close_uncached(sh_zhp);
4853 zfs_handle_t *sh_zhp;
4860 if ((sh_zhp = zfs_fs_to_auto_share(zhp)) != NULL) {
4861 zfs_refresh_properties(sh_zhp);
4862 zfs_close_uncached(sh_zhp);