summaryrefslogtreecommitdiff
path: root/usr/src/lib/libzfs/common/libzfs_impl.h
diff options
context:
space:
mode:
authoreschrock <none@none>2006-09-05 11:37:36 -0700
committereschrock <none@none>2006-09-05 11:37:36 -0700
commite9dbad6f263d5570ed7ff5443ec5b958af8c24d7 (patch)
tree7bd6d85273a4462fc4699aa9ed69e33bd69e2613 /usr/src/lib/libzfs/common/libzfs_impl.h
parentf724721be86f2d808bc08cd6be299acc214e3dc5 (diff)
downloadillumos-joyent-e9dbad6f263d5570ed7ff5443ec5b958af8c24d7.tar.gz
PSARC 2006/486 ZFS canmount property
PSARC 2006/497 ZFS create time properties PSARC 2006/502 ZFS get all datasets PSARC 2006/504 ZFS user properties 6269805 properties should be set via an nvlist. 6281585 user defined properties 6349494 'zfs list' output annoying for even moderately long dataset names 6366244 'canmount' option for container-like functionality 6367103 create-time properties 6416639 RFE: provide zfs get -a 6437808 ZFS module version should match on-disk version 6454551 'zfs create -b blocksize filesystem' should fail. 6457478 unrecognized character in error message with 'zpool create -R' command 6457865 missing device name in the error message of 'zpool clear' command 6458571 zfs_ioc_set_prop() doesn't validate input 6458614 zfs ACL #defines should use prefix 6458638 get_configs() accesses bogus memory 6458678 zvol functions should be moved out of zfs_ioctl.h 6458683 zfs_cmd_t could use more cleanup 6458691 common routines to manage zfs_cmd_t nvlists 6460398 zpool import cores on zfs_prop_get 6461029 zpool status -x noexisting-pool has incorrect error message. 6461223 index translations should live with property definitions 6461424 zpool_unmount_datasets() has some busted logic 6461427 zfs_realloc() would be useful 6461757 'zpool status' can report the wrong number of persistent errors 6461784 recursive zfs_snapshot() leaks memory
Diffstat (limited to 'usr/src/lib/libzfs/common/libzfs_impl.h')
-rw-r--r--usr/src/lib/libzfs/common/libzfs_impl.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/usr/src/lib/libzfs/common/libzfs_impl.h b/usr/src/lib/libzfs/common/libzfs_impl.h
index 3e0f737a4b..e4bc794cd8 100644
--- a/usr/src/lib/libzfs/common/libzfs_impl.h
+++ b/usr/src/lib/libzfs/common/libzfs_impl.h
@@ -60,14 +60,20 @@ struct zfs_handle {
char zfs_name[ZFS_MAXNAMELEN];
zfs_type_t zfs_type;
dmu_objset_stats_t zfs_dmustats;
+ zvol_stats_t zfs_volstats;
nvlist_t *zfs_props;
- uint64_t zfs_volsize;
- uint64_t zfs_volblocksize;
+ nvlist_t *zfs_user_props;
boolean_t zfs_mntcheck;
char *zfs_mntopts;
char zfs_root[MAXPATHLEN];
};
+/*
+ * This is different from checking zfs_type, because it will also catch
+ * snapshots of volumes.
+ */
+#define ZFS_IS_VOLUME(zhp) ((zhp)->zfs_volstats.zv_volblocksize != 0)
+
struct zpool_handle {
libzfs_handle_t *zpool_hdl;
char zpool_name[ZPOOL_MAXNAMELEN];
@@ -82,6 +88,7 @@ struct zpool_handle {
int zfs_error(libzfs_handle_t *, int, const char *, ...);
void zfs_error_aux(libzfs_handle_t *, const char *, ...);
void *zfs_alloc(libzfs_handle_t *, size_t);
+void *zfs_realloc(libzfs_handle_t *, void *, size_t, size_t);
char *zfs_strdup(libzfs_handle_t *, const char *);
int no_memory(libzfs_handle_t *);
@@ -93,6 +100,12 @@ int get_dependents(libzfs_handle_t *, boolean_t, const char *, char ***,
typedef struct prop_changelist prop_changelist_t;
+int zcmd_alloc_dst_nvlist(libzfs_handle_t *, zfs_cmd_t *, size_t);
+int zcmd_write_src_nvlist(libzfs_handle_t *, zfs_cmd_t *, nvlist_t *, size_t *);
+int zcmd_expand_dst_nvlist(libzfs_handle_t *, zfs_cmd_t *);
+int zcmd_read_dst_nvlist(libzfs_handle_t *, zfs_cmd_t *, nvlist_t **);
+void zcmd_free_nvlists(zfs_cmd_t *);
+
int changelist_prefix(prop_changelist_t *);
int changelist_postfix(prop_changelist_t *);
void changelist_rename(prop_changelist_t *, const char *, const char *);