aboutsummaryrefslogtreecommitdiffstats
path: root/include/sys
diff options
context:
space:
mode:
authorнаб <[email protected]>2021-06-03 23:50:07 +0200
committerBrian Behlendorf <[email protected]>2021-06-09 17:04:32 -0700
commit327c904615db9cfcd8c9e07cb56b8e36050a4048 (patch)
treeaee14f5621b8e6433d936d901803337a2364418c /include/sys
parentd406a695c640dd93f49f8dcb532bfa0394ad1812 (diff)
lib{efi,avl,share,tpool,zfs_core,zfsbootenv,zutil}: -fvisibility=hidden
No symbols affected in libavl No symbols affected by libtpool, but pre-ANSI declarations got purged No symbols affected by libzfs_core No symbols affected by libzfs_bootenv libefi got cleaned, gained efi_debug documentation in efi_partition.h, and removes one undocumented and unused symbol from libzfs_core: D default_vtoc_map libnvpair saw removal of these symbols: D nv_alloc_nosleep_def D nv_alloc_sleep D nv_alloc_sleep_def D nv_fixed_ops_def D nvlist_hashtable_init_size D nvpair_max_recursion libshare saw removal of these symbols from libzfs: T libshare_nfs_init T libshare_smb_init T register_fstype B smb_shares libzutil saw removal of these internal symbols from libzfs_core: T label_paths T slice_cache_compare T zpool_find_import_blkid T zpool_open_func T zutil_alloc T zutil_strdup Reviewed-by: Matthew Ahrens <[email protected]> Reviewed-by: John Kennedy <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Ahelenia Ziemiańska <[email protected]> Closes #12191
Diffstat (limited to 'include/sys')
-rw-r--r--include/sys/avl.h36
-rw-r--r--include/sys/avl_impl.h5
-rw-r--r--include/sys/efi_partition.h19
-rw-r--r--include/sys/nvpair.h443
4 files changed, 276 insertions, 227 deletions
diff --git a/include/sys/avl.h b/include/sys/avl.h
index ed3c6f86a..20e88f2a6 100644
--- a/include/sys/avl.h
+++ b/include/sys/avl.h
@@ -28,7 +28,7 @@
*/
#ifndef _AVL_H
-#define _AVL_H
+#define _AVL_H extern __attribute__((visibility("default")))
/*
* This is a private header file. Applications should not directly include
@@ -160,7 +160,7 @@ typedef uintptr_t avl_index_t;
* size - the value of sizeof(struct my_type)
* offset - the value of OFFSETOF(struct my_type, my_link)
*/
-extern void avl_create(avl_tree_t *tree,
+_AVL_H void avl_create(avl_tree_t *tree,
int (*compar) (const void *, const void *), size_t size, size_t offset);
@@ -172,7 +172,7 @@ extern void avl_create(avl_tree_t *tree,
* node - node that has the value being looked for
* where - position for use with avl_nearest() or avl_insert(), may be NULL
*/
-extern void *avl_find(avl_tree_t *tree, const void *node, avl_index_t *where);
+_AVL_H void *avl_find(avl_tree_t *tree, const void *node, avl_index_t *where);
/*
* Insert a node into the tree.
@@ -180,7 +180,7 @@ extern void *avl_find(avl_tree_t *tree, const void *node, avl_index_t *where);
* node - the node to insert
* where - position as returned from avl_find()
*/
-extern void avl_insert(avl_tree_t *tree, void *node, avl_index_t where);
+_AVL_H void avl_insert(avl_tree_t *tree, void *node, avl_index_t where);
/*
* Insert "new_data" in "tree" in the given "direction" either after
@@ -193,7 +193,7 @@ extern void avl_insert(avl_tree_t *tree, void *node, avl_index_t where);
* here - existing node in "tree"
* direction - either AVL_AFTER or AVL_BEFORE the data "here".
*/
-extern void avl_insert_here(avl_tree_t *tree, void *new_data, void *here,
+_AVL_H void avl_insert_here(avl_tree_t *tree, void *new_data, void *here,
int direction);
@@ -202,8 +202,8 @@ extern void avl_insert_here(avl_tree_t *tree, void *new_data, void *here,
* if the tree is empty.
*
*/
-extern void *avl_first(avl_tree_t *tree);
-extern void *avl_last(avl_tree_t *tree);
+_AVL_H void *avl_first(avl_tree_t *tree);
+_AVL_H void *avl_last(avl_tree_t *tree);
/*
@@ -239,7 +239,7 @@ extern void *avl_last(avl_tree_t *tree);
* else
* less = avl_nearest(tree, where, AVL_BEFORE);
*/
-extern void *avl_nearest(avl_tree_t *tree, avl_index_t where, int direction);
+_AVL_H void *avl_nearest(avl_tree_t *tree, avl_index_t where, int direction);
/*
@@ -249,7 +249,7 @@ extern void *avl_nearest(avl_tree_t *tree, avl_index_t where, int direction);
*
* node - the node to add
*/
-extern void avl_add(avl_tree_t *tree, void *node);
+_AVL_H void avl_add(avl_tree_t *tree, void *node);
/*
@@ -257,7 +257,7 @@ extern void avl_add(avl_tree_t *tree, void *node);
*
* node - the node to remove
*/
-extern void avl_remove(avl_tree_t *tree, void *node);
+_AVL_H void avl_remove(avl_tree_t *tree, void *node);
/*
* Reinsert a node only if its order has changed relative to its nearest
@@ -266,24 +266,24 @@ extern void avl_remove(avl_tree_t *tree, void *node);
* avl_update_gt() only if you know the direction in which the order of the
* node may change.
*/
-extern boolean_t avl_update(avl_tree_t *, void *);
-extern boolean_t avl_update_lt(avl_tree_t *, void *);
-extern boolean_t avl_update_gt(avl_tree_t *, void *);
+_AVL_H boolean_t avl_update(avl_tree_t *, void *);
+_AVL_H boolean_t avl_update_lt(avl_tree_t *, void *);
+_AVL_H boolean_t avl_update_gt(avl_tree_t *, void *);
/*
* Swaps the contents of the two trees.
*/
-extern void avl_swap(avl_tree_t *tree1, avl_tree_t *tree2);
+_AVL_H void avl_swap(avl_tree_t *tree1, avl_tree_t *tree2);
/*
* Return the number of nodes in the tree
*/
-extern ulong_t avl_numnodes(avl_tree_t *tree);
+_AVL_H ulong_t avl_numnodes(avl_tree_t *tree);
/*
* Return B_TRUE if there are zero nodes in the tree, B_FALSE otherwise.
*/
-extern boolean_t avl_is_empty(avl_tree_t *tree);
+_AVL_H boolean_t avl_is_empty(avl_tree_t *tree);
/*
* Used to destroy any remaining nodes in a tree. The cookie argument should
@@ -306,7 +306,7 @@ extern boolean_t avl_is_empty(avl_tree_t *tree);
* free(node);
* avl_destroy(tree);
*/
-extern void *avl_destroy_nodes(avl_tree_t *tree, void **cookie);
+_AVL_H void *avl_destroy_nodes(avl_tree_t *tree, void **cookie);
/*
@@ -314,7 +314,7 @@ extern void *avl_destroy_nodes(avl_tree_t *tree, void **cookie);
*
* tree - the empty tree to destroy
*/
-extern void avl_destroy(avl_tree_t *tree);
+_AVL_H void avl_destroy(avl_tree_t *tree);
diff --git a/include/sys/avl_impl.h b/include/sys/avl_impl.h
index fddf76906..f577ecd42 100644
--- a/include/sys/avl_impl.h
+++ b/include/sys/avl_impl.h
@@ -25,8 +25,7 @@
*/
#ifndef _AVL_IMPL_H
-#define _AVL_IMPL_H
-
+#define _AVL_IMPL_H extern __attribute__((visibility("default")))
/*
@@ -155,7 +154,7 @@ struct avl_tree {
/*
* This will only by used via AVL_NEXT() or AVL_PREV()
*/
-extern void *avl_walk(struct avl_tree *, void *, int);
+_AVL_IMPL_H void *avl_walk(struct avl_tree *, void *, int);
#ifdef __cplusplus
}
diff --git a/include/sys/efi_partition.h b/include/sys/efi_partition.h
index fbb58013e..cda2c98e5 100644
--- a/include/sys/efi_partition.h
+++ b/include/sys/efi_partition.h
@@ -24,7 +24,7 @@
*/
#ifndef _SYS_EFI_PARTITION_H
-#define _SYS_EFI_PARTITION_H
+#define _SYS_EFI_PARTITION_H extern __attribute__((visibility("default")))
#include <sys/uuid.h>
@@ -363,14 +363,15 @@ struct partition64 {
#endif
#ifndef _KERNEL
-extern int efi_alloc_and_init(int, uint32_t, struct dk_gpt **);
-extern int efi_alloc_and_read(int, struct dk_gpt **);
-extern int efi_write(int, struct dk_gpt *);
-extern int efi_rescan(int);
-extern void efi_free(struct dk_gpt *);
-extern int efi_type(int);
-extern void efi_err_check(struct dk_gpt *);
-extern int efi_use_whole_disk(int fd);
+_SYS_EFI_PARTITION_H int efi_debug;
+_SYS_EFI_PARTITION_H int efi_alloc_and_init(int, uint32_t, struct dk_gpt **);
+_SYS_EFI_PARTITION_H int efi_alloc_and_read(int, struct dk_gpt **);
+_SYS_EFI_PARTITION_H int efi_write(int, struct dk_gpt *);
+_SYS_EFI_PARTITION_H int efi_rescan(int);
+_SYS_EFI_PARTITION_H void efi_free(struct dk_gpt *);
+_SYS_EFI_PARTITION_H int efi_type(int);
+_SYS_EFI_PARTITION_H void efi_err_check(struct dk_gpt *);
+_SYS_EFI_PARTITION_H int efi_use_whole_disk(int fd);
#endif
#ifdef __cplusplus
diff --git a/include/sys/nvpair.h b/include/sys/nvpair.h
index b0be8bd7a..76d383a3c 100644
--- a/include/sys/nvpair.h
+++ b/include/sys/nvpair.h
@@ -24,7 +24,7 @@
*/
#ifndef _SYS_NVPAIR_H
-#define _SYS_NVPAIR_H
+#define _SYS_NVPAIR_H extern __attribute__((visibility("default")))
#include <sys/types.h>
#include <sys/time.h>
@@ -135,221 +135,270 @@ struct nv_alloc_ops {
void (*nv_ao_reset)(nv_alloc_t *);
};
-extern const nv_alloc_ops_t *nv_fixed_ops;
-extern nv_alloc_t *nv_alloc_nosleep;
+_SYS_NVPAIR_H const nv_alloc_ops_t *nv_fixed_ops;
+_SYS_NVPAIR_H nv_alloc_t *nv_alloc_nosleep;
#if defined(_KERNEL)
-extern nv_alloc_t *nv_alloc_sleep;
-extern nv_alloc_t *nv_alloc_pushpage;
+_SYS_NVPAIR_H nv_alloc_t *nv_alloc_sleep;
+_SYS_NVPAIR_H nv_alloc_t *nv_alloc_pushpage;
#endif
-int nv_alloc_init(nv_alloc_t *, const nv_alloc_ops_t *, /* args */ ...);
-void nv_alloc_reset(nv_alloc_t *);
-void nv_alloc_fini(nv_alloc_t *);
+_SYS_NVPAIR_H int nv_alloc_init(nv_alloc_t *, const nv_alloc_ops_t *,
+ /* args */ ...);
+_SYS_NVPAIR_H void nv_alloc_reset(nv_alloc_t *);
+_SYS_NVPAIR_H void nv_alloc_fini(nv_alloc_t *);
/* list management */
-int nvlist_alloc(nvlist_t **, uint_t, int);
-void nvlist_free(nvlist_t *);
-int nvlist_size(nvlist_t *, size_t *, int);
-int nvlist_pack(nvlist_t *, char **, size_t *, int, int);
-int nvlist_unpack(char *, size_t, nvlist_t **, int);
-int nvlist_dup(nvlist_t *, nvlist_t **, int);
-int nvlist_merge(nvlist_t *, nvlist_t *, int);
-
-uint_t nvlist_nvflag(nvlist_t *);
-
-int nvlist_xalloc(nvlist_t **, uint_t, nv_alloc_t *);
-int nvlist_xpack(nvlist_t *, char **, size_t *, int, nv_alloc_t *);
-int nvlist_xunpack(char *, size_t, nvlist_t **, nv_alloc_t *);
-int nvlist_xdup(nvlist_t *, nvlist_t **, nv_alloc_t *);
-nv_alloc_t *nvlist_lookup_nv_alloc(nvlist_t *);
-
-int nvlist_add_nvpair(nvlist_t *, nvpair_t *);
-int nvlist_add_boolean(nvlist_t *, const char *);
-int nvlist_add_boolean_value(nvlist_t *, const char *, boolean_t);
-int nvlist_add_byte(nvlist_t *, const char *, uchar_t);
-int nvlist_add_int8(nvlist_t *, const char *, int8_t);
-int nvlist_add_uint8(nvlist_t *, const char *, uint8_t);
-int nvlist_add_int16(nvlist_t *, const char *, int16_t);
-int nvlist_add_uint16(nvlist_t *, const char *, uint16_t);
-int nvlist_add_int32(nvlist_t *, const char *, int32_t);
-int nvlist_add_uint32(nvlist_t *, const char *, uint32_t);
-int nvlist_add_int64(nvlist_t *, const char *, int64_t);
-int nvlist_add_uint64(nvlist_t *, const char *, uint64_t);
-int nvlist_add_string(nvlist_t *, const char *, const char *);
-int nvlist_add_nvlist(nvlist_t *, const char *, nvlist_t *);
-int nvlist_add_boolean_array(nvlist_t *, const char *, boolean_t *, uint_t);
-int nvlist_add_byte_array(nvlist_t *, const char *, uchar_t *, uint_t);
-int nvlist_add_int8_array(nvlist_t *, const char *, int8_t *, uint_t);
-int nvlist_add_uint8_array(nvlist_t *, const char *, uint8_t *, uint_t);
-int nvlist_add_int16_array(nvlist_t *, const char *, int16_t *, uint_t);
-int nvlist_add_uint16_array(nvlist_t *, const char *, uint16_t *, uint_t);
-int nvlist_add_int32_array(nvlist_t *, const char *, int32_t *, uint_t);
-int nvlist_add_uint32_array(nvlist_t *, const char *, uint32_t *, uint_t);
-int nvlist_add_int64_array(nvlist_t *, const char *, int64_t *, uint_t);
-int nvlist_add_uint64_array(nvlist_t *, const char *, uint64_t *, uint_t);
-int nvlist_add_string_array(nvlist_t *, const char *, char *const *, uint_t);
-int nvlist_add_nvlist_array(nvlist_t *, const char *, nvlist_t **, uint_t);
-int nvlist_add_hrtime(nvlist_t *, const char *, hrtime_t);
+_SYS_NVPAIR_H int nvlist_alloc(nvlist_t **, uint_t, int);
+_SYS_NVPAIR_H void nvlist_free(nvlist_t *);
+_SYS_NVPAIR_H int nvlist_size(nvlist_t *, size_t *, int);
+_SYS_NVPAIR_H int nvlist_pack(nvlist_t *, char **, size_t *, int, int);
+_SYS_NVPAIR_H int nvlist_unpack(char *, size_t, nvlist_t **, int);
+_SYS_NVPAIR_H int nvlist_dup(nvlist_t *, nvlist_t **, int);
+_SYS_NVPAIR_H int nvlist_merge(nvlist_t *, nvlist_t *, int);
+
+_SYS_NVPAIR_H uint_t nvlist_nvflag(nvlist_t *);
+
+_SYS_NVPAIR_H int nvlist_xalloc(nvlist_t **, uint_t, nv_alloc_t *);
+_SYS_NVPAIR_H int nvlist_xpack(nvlist_t *, char **, size_t *, int,
+ nv_alloc_t *);
+_SYS_NVPAIR_H int nvlist_xunpack(char *, size_t, nvlist_t **, nv_alloc_t *);
+_SYS_NVPAIR_H int nvlist_xdup(nvlist_t *, nvlist_t **, nv_alloc_t *);
+_SYS_NVPAIR_H nv_alloc_t *nvlist_lookup_nv_alloc(nvlist_t *);
+
+_SYS_NVPAIR_H int nvlist_add_nvpair(nvlist_t *, nvpair_t *);
+_SYS_NVPAIR_H int nvlist_add_boolean(nvlist_t *, const char *);
+_SYS_NVPAIR_H int nvlist_add_boolean_value(nvlist_t *, const char *, boolean_t);
+_SYS_NVPAIR_H int nvlist_add_byte(nvlist_t *, const char *, uchar_t);
+_SYS_NVPAIR_H int nvlist_add_int8(nvlist_t *, const char *, int8_t);
+_SYS_NVPAIR_H int nvlist_add_uint8(nvlist_t *, const char *, uint8_t);
+_SYS_NVPAIR_H int nvlist_add_int16(nvlist_t *, const char *, int16_t);
+_SYS_NVPAIR_H int nvlist_add_uint16(nvlist_t *, const char *, uint16_t);
+_SYS_NVPAIR_H int nvlist_add_int32(nvlist_t *, const char *, int32_t);
+_SYS_NVPAIR_H int nvlist_add_uint32(nvlist_t *, const char *, uint32_t);
+_SYS_NVPAIR_H int nvlist_add_int64(nvlist_t *, const char *, int64_t);
+_SYS_NVPAIR_H int nvlist_add_uint64(nvlist_t *, const char *, uint64_t);
+_SYS_NVPAIR_H int nvlist_add_string(nvlist_t *, const char *, const char *);
+_SYS_NVPAIR_H int nvlist_add_nvlist(nvlist_t *, const char *, nvlist_t *);
+_SYS_NVPAIR_H int nvlist_add_boolean_array(nvlist_t *, const char *,
+ boolean_t *, uint_t);
+_SYS_NVPAIR_H int nvlist_add_byte_array(nvlist_t *, const char *, uchar_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_int8_array(nvlist_t *, const char *, int8_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_uint8_array(nvlist_t *, const char *, uint8_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_int16_array(nvlist_t *, const char *, int16_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_uint16_array(nvlist_t *, const char *, uint16_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_int32_array(nvlist_t *, const char *, int32_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_uint32_array(nvlist_t *, const char *, uint32_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_int64_array(nvlist_t *, const char *, int64_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_uint64_array(nvlist_t *, const char *, uint64_t *,
+ uint_t);
+_SYS_NVPAIR_H int nvlist_add_string_array(nvlist_t *, const char *,
+ char * const *, uint_t);
+_SYS_NVPAIR_H int nvlist_add_nvlist_array(nvlist_t *, const char *,
+ nvlist_t **, uint_t);
+_SYS_NVPAIR_H int nvlist_add_hrtime(nvlist_t *, const char *, hrtime_t);
#if !defined(_KERNEL) && !defined(_STANDALONE)
-int nvlist_add_double(nvlist_t *, const char *, double);
+_SYS_NVPAIR_H int nvlist_add_double(nvlist_t *, const char *, double);
#endif
-int nvlist_remove(nvlist_t *, const char *, data_type_t);
-int nvlist_remove_all(nvlist_t *, const char *);
-int nvlist_remove_nvpair(nvlist_t *, nvpair_t *);
-
-int nvlist_lookup_boolean(nvlist_t *, const char *);
-int nvlist_lookup_boolean_value(nvlist_t *, const char *, boolean_t *);
-int nvlist_lookup_byte(nvlist_t *, const char *, uchar_t *);
-int nvlist_lookup_int8(nvlist_t *, const char *, int8_t *);
-int nvlist_lookup_uint8(nvlist_t *, const char *, uint8_t *);
-int nvlist_lookup_int16(nvlist_t *, const char *, int16_t *);
-int nvlist_lookup_uint16(nvlist_t *, const char *, uint16_t *);
-int nvlist_lookup_int32(nvlist_t *, const char *, int32_t *);
-int nvlist_lookup_uint32(nvlist_t *, const char *, uint32_t *);
-int nvlist_lookup_int64(nvlist_t *, const char *, int64_t *);
-int nvlist_lookup_uint64(nvlist_t *, const char *, uint64_t *);
-int nvlist_lookup_string(nvlist_t *, const char *, char **);
-int nvlist_lookup_nvlist(nvlist_t *, const char *, nvlist_t **);
-int nvlist_lookup_boolean_array(nvlist_t *, const char *,
+_SYS_NVPAIR_H int nvlist_remove(nvlist_t *, const char *, data_type_t);
+_SYS_NVPAIR_H int nvlist_remove_all(nvlist_t *, const char *);
+_SYS_NVPAIR_H int nvlist_remove_nvpair(nvlist_t *, nvpair_t *);
+
+_SYS_NVPAIR_H int nvlist_lookup_boolean(nvlist_t *, const char *);
+_SYS_NVPAIR_H int nvlist_lookup_boolean_value(nvlist_t *, const char *,
+ boolean_t *);
+_SYS_NVPAIR_H int nvlist_lookup_byte(nvlist_t *, const char *, uchar_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int8(nvlist_t *, const char *, int8_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint8(nvlist_t *, const char *, uint8_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int16(nvlist_t *, const char *, int16_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint16(nvlist_t *, const char *, uint16_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int32(nvlist_t *, const char *, int32_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint32(nvlist_t *, const char *, uint32_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int64(nvlist_t *, const char *, int64_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint64(nvlist_t *, const char *, uint64_t *);
+_SYS_NVPAIR_H int nvlist_lookup_string(nvlist_t *, const char *, char **);
+_SYS_NVPAIR_H int nvlist_lookup_nvlist(nvlist_t *, const char *, nvlist_t **);
+_SYS_NVPAIR_H int nvlist_lookup_boolean_array(nvlist_t *, const char *,
boolean_t **, uint_t *);
-int nvlist_lookup_byte_array(nvlist_t *, const char *, uchar_t **, uint_t *);
-int nvlist_lookup_int8_array(nvlist_t *, const char *, int8_t **, uint_t *);
-int nvlist_lookup_uint8_array(nvlist_t *, const char *, uint8_t **, uint_t *);
-int nvlist_lookup_int16_array(nvlist_t *, const char *, int16_t **, uint_t *);
-int nvlist_lookup_uint16_array(nvlist_t *, const char *, uint16_t **, uint_t *);
-int nvlist_lookup_int32_array(nvlist_t *, const char *, int32_t **, uint_t *);
-int nvlist_lookup_uint32_array(nvlist_t *, const char *, uint32_t **, uint_t *);
-int nvlist_lookup_int64_array(nvlist_t *, const char *, int64_t **, uint_t *);
-int nvlist_lookup_uint64_array(nvlist_t *, const char *, uint64_t **, uint_t *);
-int nvlist_lookup_string_array(nvlist_t *, const char *, char ***, uint_t *);
-int nvlist_lookup_nvlist_array(nvlist_t *, const char *,
+_SYS_NVPAIR_H int nvlist_lookup_byte_array(nvlist_t *, const char *, uchar_t **,
+ uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int8_array(nvlist_t *, const char *, int8_t **,
+ uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint8_array(nvlist_t *, const char *,
+ uint8_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int16_array(nvlist_t *, const char *,
+ int16_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint16_array(nvlist_t *, const char *,
+ uint16_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int32_array(nvlist_t *, const char *,
+ int32_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint32_array(nvlist_t *, const char *,
+ uint32_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_int64_array(nvlist_t *, const char *,
+ int64_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_uint64_array(nvlist_t *, const char *,
+ uint64_t **, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_string_array(nvlist_t *, const char *,
+ char ***, uint_t *);
+_SYS_NVPAIR_H int nvlist_lookup_nvlist_array(nvlist_t *, const char *,
nvlist_t ***, uint_t *);
-int nvlist_lookup_hrtime(nvlist_t *, const char *, hrtime_t *);
-int nvlist_lookup_pairs(nvlist_t *, int, ...);
+_SYS_NVPAIR_H int nvlist_lookup_hrtime(nvlist_t *, const char *, hrtime_t *);
+_SYS_NVPAIR_H int nvlist_lookup_pairs(nvlist_t *, int, ...);
#if !defined(_KERNEL) && !defined(_STANDALONE)
-int nvlist_lookup_double(nvlist_t *, const char *, double *);
+_SYS_NVPAIR_H int nvlist_lookup_double(nvlist_t *, const char *, double *);
#endif
-int nvlist_lookup_nvpair(nvlist_t *, const char *, nvpair_t **);
-int nvlist_lookup_nvpair_embedded_index(nvlist_t *, const char *, nvpair_t **,
- int *, char **);
-boolean_t nvlist_exists(nvlist_t *, const char *);
-boolean_t nvlist_empty(nvlist_t *);
+_SYS_NVPAIR_H int nvlist_lookup_nvpair(nvlist_t *, const char *, nvpair_t **);
+_SYS_NVPAIR_H int nvlist_lookup_nvpair_embedded_index(nvlist_t *, const char *,
+ nvpair_t **, int *, char **);
+_SYS_NVPAIR_H boolean_t nvlist_exists(nvlist_t *, const char *);
+_SYS_NVPAIR_H boolean_t nvlist_empty(nvlist_t *);
/* processing nvpair */
-nvpair_t *nvlist_next_nvpair(nvlist_t *, nvpair_t *);
-nvpair_t *nvlist_prev_nvpair(nvlist_t *, nvpair_t *);
-char *nvpair_name(nvpair_t *);
-data_type_t nvpair_type(nvpair_t *);
-int nvpair_type_is_array(nvpair_t *);
-int nvpair_value_boolean_value(nvpair_t *, boolean_t *);
-int nvpair_value_byte(nvpair_t *, uchar_t *);
-int nvpair_value_int8(nvpair_t *, int8_t *);
-int nvpair_value_uint8(nvpair_t *, uint8_t *);
-int nvpair_value_int16(nvpair_t *, int16_t *);
-int nvpair_value_uint16(nvpair_t *, uint16_t *);
-int nvpair_value_int32(nvpair_t *, int32_t *);
-int nvpair_value_uint32(nvpair_t *, uint32_t *);
-int nvpair_value_int64(nvpair_t *, int64_t *);
-int nvpair_value_uint64(nvpair_t *, uint64_t *);
-int nvpair_value_string(nvpair_t *, char **);
-int nvpair_value_nvlist(nvpair_t *, nvlist_t **);
-int nvpair_value_boolean_array(nvpair_t *, boolean_t **, uint_t *);
-int nvpair_value_byte_array(nvpair_t *, uchar_t **, uint_t *);
-int nvpair_value_int8_array(nvpair_t *, int8_t **, uint_t *);
-int nvpair_value_uint8_array(nvpair_t *, uint8_t **, uint_t *);
-int nvpair_value_int16_array(nvpair_t *, int16_t **, uint_t *);
-int nvpair_value_uint16_array(nvpair_t *, uint16_t **, uint_t *);
-int nvpair_value_int32_array(nvpair_t *, int32_t **, uint_t *);
-int nvpair_value_uint32_array(nvpair_t *, uint32_t **, uint_t *);
-int nvpair_value_int64_array(nvpair_t *, int64_t **, uint_t *);
-int nvpair_value_uint64_array(nvpair_t *, uint64_t **, uint_t *);
-int nvpair_value_string_array(nvpair_t *, char ***, uint_t *);
-int nvpair_value_nvlist_array(nvpair_t *, nvlist_t ***, uint_t *);
-int nvpair_value_hrtime(nvpair_t *, hrtime_t *);
+_SYS_NVPAIR_H nvpair_t *nvlist_next_nvpair(nvlist_t *, nvpair_t *);
+_SYS_NVPAIR_H nvpair_t *nvlist_prev_nvpair(nvlist_t *, nvpair_t *);
+_SYS_NVPAIR_H char *nvpair_name(nvpair_t *);
+_SYS_NVPAIR_H data_type_t nvpair_type(nvpair_t *);
+_SYS_NVPAIR_H int nvpair_type_is_array(nvpair_t *);
+_SYS_NVPAIR_H int nvpair_value_boolean_value(nvpair_t *, boolean_t *);
+_SYS_NVPAIR_H int nvpair_value_byte(nvpair_t *, uchar_t *);
+_SYS_NVPAIR_H int nvpair_value_int8(nvpair_t *, int8_t *);
+_SYS_NVPAIR_H int nvpair_value_uint8(nvpair_t *, uint8_t *);
+_SYS_NVPAIR_H int nvpair_value_int16(nvpair_t *, int16_t *);
+_SYS_NVPAIR_H int nvpair_value_uint16(nvpair_t *, uint16_t *);
+_SYS_NVPAIR_H int nvpair_value_int32(nvpair_t *, int32_t *);
+_SYS_NVPAIR_H int nvpair_value_uint32(nvpair_t *, uint32_t *);
+_SYS_NVPAIR_H int nvpair_value_int64(nvpair_t *, int64_t *);
+_SYS_NVPAIR_H int nvpair_value_uint64(nvpair_t *, uint64_t *);
+_SYS_NVPAIR_H int nvpair_value_string(nvpair_t *, char **);
+_SYS_NVPAIR_H int nvpair_value_nvlist(nvpair_t *, nvlist_t **);
+_SYS_NVPAIR_H int nvpair_value_boolean_array(nvpair_t *, boolean_t **,
+ uint_t *);
+_SYS_NVPAIR_H int nvpair_value_byte_array(nvpair_t *, uchar_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_int8_array(nvpair_t *, int8_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_uint8_array(nvpair_t *, uint8_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_int16_array(nvpair_t *, int16_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_uint16_array(nvpair_t *, uint16_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_int32_array(nvpair_t *, int32_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_uint32_array(nvpair_t *, uint32_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_int64_array(nvpair_t *, int64_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_uint64_array(nvpair_t *, uint64_t **, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_string_array(nvpair_t *, char ***, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_nvlist_array(nvpair_t *, nvlist_t ***, uint_t *);
+_SYS_NVPAIR_H int nvpair_value_hrtime(nvpair_t *, hrtime_t *);
#if !defined(_KERNEL) && !defined(_STANDALONE)
-int nvpair_value_double(nvpair_t *, double *);
+_SYS_NVPAIR_H int nvpair_value_double(nvpair_t *, double *);
#endif
-nvlist_t *fnvlist_alloc(void);
-void fnvlist_free(nvlist_t *);
-size_t fnvlist_size(nvlist_t *);
-char *fnvlist_pack(nvlist_t *, size_t *);
-void fnvlist_pack_free(char *, size_t);
-nvlist_t *fnvlist_unpack(char *, size_t);
-nvlist_t *fnvlist_dup(nvlist_t *);
-void fnvlist_merge(nvlist_t *, nvlist_t *);
-size_t fnvlist_num_pairs(nvlist_t *);
-
-void fnvlist_add_boolean(nvlist_t *, const char *);
-void fnvlist_add_boolean_value(nvlist_t *, const char *, boolean_t);
-void fnvlist_add_byte(nvlist_t *, const char *, uchar_t);
-void fnvlist_add_int8(nvlist_t *, const char *, int8_t);
-void fnvlist_add_uint8(nvlist_t *, const char *, uint8_t);
-void fnvlist_add_int16(nvlist_t *, const char *, int16_t);
-void fnvlist_add_uint16(nvlist_t *, const char *, uint16_t);
-void fnvlist_add_int32(nvlist_t *, const char *, int32_t);
-void fnvlist_add_uint32(nvlist_t *, const char *, uint32_t);
-void fnvlist_add_int64(nvlist_t *, const char *, int64_t);
-void fnvlist_add_uint64(nvlist_t *, const char *, uint64_t);
-void fnvlist_add_string(nvlist_t *, const char *, const char *);
-void fnvlist_add_nvlist(nvlist_t *, const char *, nvlist_t *);
-void fnvlist_add_nvpair(nvlist_t *, nvpair_t *);
-void fnvlist_add_boolean_array(nvlist_t *, const char *, boolean_t *, uint_t);
-void fnvlist_add_byte_array(nvlist_t *, const char *, uchar_t *, uint_t);
-void fnvlist_add_int8_array(nvlist_t *, const char *, int8_t *, uint_t);
-void fnvlist_add_uint8_array(nvlist_t *, const char *, uint8_t *, uint_t);
-void fnvlist_add_int16_array(nvlist_t *, const char *, int16_t *, uint_t);
-void fnvlist_add_uint16_array(nvlist_t *, const char *, uint16_t *, uint_t);
-void fnvlist_add_int32_array(nvlist_t *, const char *, int32_t *, uint_t);
-void fnvlist_add_uint32_array(nvlist_t *, const char *, uint32_t *, uint_t);
-void fnvlist_add_int64_array(nvlist_t *, const char *, int64_t *, uint_t);
-void fnvlist_add_uint64_array(nvlist_t *, const char *, uint64_t *, uint_t);
-void fnvlist_add_string_array(nvlist_t *, const char *, char * const *, uint_t);
-void fnvlist_add_nvlist_array(nvlist_t *, const char *, nvlist_t **, uint_t);
-
-void fnvlist_remove(nvlist_t *, const char *);
-void fnvlist_remove_nvpair(nvlist_t *, nvpair_t *);
-
-nvpair_t *fnvlist_lookup_nvpair(nvlist_t *, const char *);
-boolean_t fnvlist_lookup_boolean(nvlist_t *, const char *);
-boolean_t fnvlist_lookup_boolean_value(nvlist_t *, const char *);
-uchar_t fnvlist_lookup_byte(nvlist_t *, const char *);
-int8_t fnvlist_lookup_int8(nvlist_t *, const char *);
-int16_t fnvlist_lookup_int16(nvlist_t *, const char *);
-int32_t fnvlist_lookup_int32(nvlist_t *, const char *);
-int64_t fnvlist_lookup_int64(nvlist_t *, const char *);
-uint8_t fnvlist_lookup_uint8(nvlist_t *, const char *);
-uint16_t fnvlist_lookup_uint16(nvlist_t *, const char *);
-uint32_t fnvlist_lookup_uint32(nvlist_t *, const char *);
-uint64_t fnvlist_lookup_uint64(nvlist_t *, const char *);
-char *fnvlist_lookup_string(nvlist_t *, const char *);
-nvlist_t *fnvlist_lookup_nvlist(nvlist_t *, const char *);
-boolean_t *fnvlist_lookup_boolean_array(nvlist_t *, const char *, uint_t *);
-uchar_t *fnvlist_lookup_byte_array(nvlist_t *, const char *, uint_t *);
-int8_t *fnvlist_lookup_int8_array(nvlist_t *, const char *, uint_t *);
-uint8_t *fnvlist_lookup_uint8_array(nvlist_t *, const char *, uint_t *);
-int16_t *fnvlist_lookup_int16_array(nvlist_t *, const char *, uint_t *);
-uint16_t *fnvlist_lookup_uint16_array(nvlist_t *, const char *, uint_t *);
-int32_t *fnvlist_lookup_int32_array(nvlist_t *, const char *, uint_t *);
-uint32_t *fnvlist_lookup_uint32_array(nvlist_t *, const char *, uint_t *);
-int64_t *fnvlist_lookup_int64_array(nvlist_t *, const char *, uint_t *);
-uint64_t *fnvlist_lookup_uint64_array(nvlist_t *, const char *, uint_t *);
-
-boolean_t fnvpair_value_boolean_value(nvpair_t *nvp);
-uchar_t fnvpair_value_byte(nvpair_t *nvp);
-int8_t fnvpair_value_int8(nvpair_t *nvp);
-int16_t fnvpair_value_int16(nvpair_t *nvp);
-int32_t fnvpair_value_int32(nvpair_t *nvp);
-int64_t fnvpair_value_int64(nvpair_t *nvp);
-uint8_t fnvpair_value_uint8(nvpair_t *nvp);
-uint16_t fnvpair_value_uint16(nvpair_t *nvp);
-uint32_t fnvpair_value_uint32(nvpair_t *nvp);
-uint64_t fnvpair_value_uint64(nvpair_t *nvp);
-char *fnvpair_value_string(nvpair_t *nvp);
-nvlist_t *fnvpair_value_nvlist(nvpair_t *nvp);
+_SYS_NVPAIR_H nvlist_t *fnvlist_alloc(void);
+_SYS_NVPAIR_H void fnvlist_free(nvlist_t *);
+_SYS_NVPAIR_H size_t fnvlist_size(nvlist_t *);
+_SYS_NVPAIR_H char *fnvlist_pack(nvlist_t *, size_t *);
+_SYS_NVPAIR_H void fnvlist_pack_free(char *, size_t);
+_SYS_NVPAIR_H nvlist_t *fnvlist_unpack(char *, size_t);
+_SYS_NVPAIR_H nvlist_t *fnvlist_dup(nvlist_t *);
+_SYS_NVPAIR_H void fnvlist_merge(nvlist_t *, nvlist_t *);
+_SYS_NVPAIR_H size_t fnvlist_num_pairs(nvlist_t *);
+
+_SYS_NVPAIR_H void fnvlist_add_boolean(nvlist_t *, const char *);
+_SYS_NVPAIR_H void fnvlist_add_boolean_value(nvlist_t *, const char *,
+ boolean_t);
+_SYS_NVPAIR_H void fnvlist_add_byte(nvlist_t *, const char *, uchar_t);
+_SYS_NVPAIR_H void fnvlist_add_int8(nvlist_t *, const char *, int8_t);
+_SYS_NVPAIR_H void fnvlist_add_uint8(nvlist_t *, const char *, uint8_t);
+_SYS_NVPAIR_H void fnvlist_add_int16(nvlist_t *, const char *, int16_t);
+_SYS_NVPAIR_H void fnvlist_add_uint16(nvlist_t *, const char *, uint16_t);
+_SYS_NVPAIR_H void fnvlist_add_int32(nvlist_t *, const char *, int32_t);
+_SYS_NVPAIR_H void fnvlist_add_uint32(nvlist_t *, const char *, uint32_t);
+_SYS_NVPAIR_H void fnvlist_add_int64(nvlist_t *, const char *, int64_t);
+_SYS_NVPAIR_H void fnvlist_add_uint64(nvlist_t *, const char *, uint64_t);
+_SYS_NVPAIR_H void fnvlist_add_string(nvlist_t *, const char *, const char *);
+_SYS_NVPAIR_H void fnvlist_add_nvlist(nvlist_t *, const char *, nvlist_t *);
+_SYS_NVPAIR_H void fnvlist_add_nvpair(nvlist_t *, nvpair_t *);
+_SYS_NVPAIR_H void fnvlist_add_boolean_array(nvlist_t *, const char *,
+ boolean_t *, uint_t);
+_SYS_NVPAIR_H void fnvlist_add_byte_array(nvlist_t *, const char *, uchar_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_int8_array(nvlist_t *, const char *, int8_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_uint8_array(nvlist_t *, const char *, uint8_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_int16_array(nvlist_t *, const char *, int16_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_uint16_array(nvlist_t *, const char *,
+ uint16_t *, uint_t);
+_SYS_NVPAIR_H void fnvlist_add_int32_array(nvlist_t *, const char *, int32_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_uint32_array(nvlist_t *, const char *,
+ uint32_t *, uint_t);
+_SYS_NVPAIR_H void fnvlist_add_int64_array(nvlist_t *, const char *, int64_t *,
+ uint_t);
+_SYS_NVPAIR_H void fnvlist_add_uint64_array(nvlist_t *, const char *,
+ uint64_t *, uint_t);
+_SYS_NVPAIR_H void fnvlist_add_string_array(nvlist_t *, const char *,
+ char * const *, uint_t);
+_SYS_NVPAIR_H void fnvlist_add_nvlist_array(nvlist_t *, const char *,
+ nvlist_t **, uint_t);
+
+_SYS_NVPAIR_H void fnvlist_remove(nvlist_t *, const char *);
+_SYS_NVPAIR_H void fnvlist_remove_nvpair(nvlist_t *, nvpair_t *);
+
+_SYS_NVPAIR_H nvpair_t *fnvlist_lookup_nvpair(nvlist_t *, const char *);
+_SYS_NVPAIR_H boolean_t fnvlist_lookup_boolean(nvlist_t *, const char *);
+_SYS_NVPAIR_H boolean_t fnvlist_lookup_boolean_value(nvlist_t *, const char *);
+_SYS_NVPAIR_H uchar_t fnvlist_lookup_byte(nvlist_t *, const char *);
+_SYS_NVPAIR_H int8_t fnvlist_lookup_int8(nvlist_t *, const char *);
+_SYS_NVPAIR_H int16_t fnvlist_lookup_int16(nvlist_t *, const char *);
+_SYS_NVPAIR_H int32_t fnvlist_lookup_int32(nvlist_t *, const char *);
+_SYS_NVPAIR_H int64_t fnvlist_lookup_int64(nvlist_t *, const char *);
+_SYS_NVPAIR_H uint8_t fnvlist_lookup_uint8(nvlist_t *, const char *);
+_SYS_NVPAIR_H uint16_t fnvlist_lookup_uint16(nvlist_t *, const char *);
+_SYS_NVPAIR_H uint32_t fnvlist_lookup_uint32(nvlist_t *, const char *);
+_SYS_NVPAIR_H uint64_t fnvlist_lookup_uint64(nvlist_t *, const char *);
+_SYS_NVPAIR_H char *fnvlist_lookup_string(nvlist_t *, const char *);
+_SYS_NVPAIR_H nvlist_t *fnvlist_lookup_nvlist(nvlist_t *, const char *);
+_SYS_NVPAIR_H boolean_t *fnvlist_lookup_boolean_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H uchar_t *fnvlist_lookup_byte_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H int8_t *fnvlist_lookup_int8_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H uint8_t *fnvlist_lookup_uint8_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H int16_t *fnvlist_lookup_int16_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H uint16_t *fnvlist_lookup_uint16_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H int32_t *fnvlist_lookup_int32_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H uint32_t *fnvlist_lookup_uint32_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H int64_t *fnvlist_lookup_int64_array(nvlist_t *, const char *,
+ uint_t *);
+_SYS_NVPAIR_H uint64_t *fnvlist_lookup_uint64_array(nvlist_t *, const char *,
+ uint_t *);
+
+_SYS_NVPAIR_H boolean_t fnvpair_value_boolean_value(nvpair_t *nvp);
+_SYS_NVPAIR_H uchar_t fnvpair_value_byte(nvpair_t *nvp);
+_SYS_NVPAIR_H int8_t fnvpair_value_int8(nvpair_t *nvp);
+_SYS_NVPAIR_H int16_t fnvpair_value_int16(nvpair_t *nvp);
+_SYS_NVPAIR_H int32_t fnvpair_value_int32(nvpair_t *nvp);
+_SYS_NVPAIR_H int64_t fnvpair_value_int64(nvpair_t *nvp);
+_SYS_NVPAIR_H uint8_t fnvpair_value_uint8(nvpair_t *nvp);
+_SYS_NVPAIR_H uint16_t fnvpair_value_uint16(nvpair_t *nvp);
+_SYS_NVPAIR_H uint32_t fnvpair_value_uint32(nvpair_t *nvp);
+_SYS_NVPAIR_H uint64_t fnvpair_value_uint64(nvpair_t *nvp);
+_SYS_NVPAIR_H char *fnvpair_value_string(nvpair_t *nvp);
+_SYS_NVPAIR_H nvlist_t *fnvpair_value_nvlist(nvpair_t *nvp);
#ifdef __cplusplus
}