diff options
author | Arvind Sankar <[email protected]> | 2020-06-15 14:30:37 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2020-06-18 12:20:38 -0700 |
commit | 65c7cc49bfcf49d38fc84552a17d7e8a3268e58e (patch) | |
tree | 4740b896f8b5fc114ae9a96c6581776799ffeb3a /lib | |
parent | 1fa5c7af3314b4c556bd86e3a49e3497a5ed72ed (diff) |
Mark functions as static
Mark functions used only in the same translation unit as static. This
only includes functions that do not have a prototype in a header file
either.
Reviewed-by: Ryan Moeller <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Arvind Sankar <[email protected]>
Closes #10470
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libzfs/libzfs_dataset.c | 8 | ||||
-rw-r--r-- | lib/libzfs/libzfs_iter.c | 2 | ||||
-rw-r--r-- | lib/libzfs/libzfs_mount.c | 2 | ||||
-rw-r--r-- | lib/libzfs/libzfs_pool.c | 4 | ||||
-rw-r--r-- | lib/libzfs/libzfs_sendrecv.c | 4 | ||||
-rw-r--r-- | lib/libzfs/libzfs_util.c | 2 |
6 files changed, 11 insertions, 11 deletions
diff --git a/lib/libzfs/libzfs_dataset.c b/lib/libzfs/libzfs_dataset.c index 90c6b68e3..4f1dec138 100644 --- a/lib/libzfs/libzfs_dataset.c +++ b/lib/libzfs/libzfs_dataset.c @@ -806,7 +806,7 @@ libzfs_mnttab_init(libzfs_handle_t *hdl) sizeof (mnttab_node_t), offsetof(mnttab_node_t, mtn_node)); } -int +static int libzfs_mnttab_update(libzfs_handle_t *hdl) { struct mnttab entry; @@ -1620,7 +1620,7 @@ error: return (NULL); } -int +static int zfs_add_synthetic_resv(zfs_handle_t *zhp, nvlist_t *nvl) { uint64_t old_volsize; @@ -2551,7 +2551,7 @@ struct get_clones_arg { char buf[ZFS_MAX_DATASET_NAME_LEN]; }; -int +static int get_clones_cb(zfs_handle_t *zhp, void *arg) { struct get_clones_arg *gca = arg; @@ -3129,7 +3129,7 @@ zfs_prop_get_int(zfs_handle_t *zhp, zfs_prop_t prop) return (val); } -int +static int zfs_prop_set_int(zfs_handle_t *zhp, zfs_prop_t prop, uint64_t val) { char buf[64]; diff --git a/lib/libzfs/libzfs_iter.c b/lib/libzfs/libzfs_iter.c index f76162bb4..7ee326bc6 100644 --- a/lib/libzfs/libzfs_iter.c +++ b/lib/libzfs/libzfs_iter.c @@ -38,7 +38,7 @@ #include "libzfs_impl.h" -int +static int zfs_iter_clones(zfs_handle_t *zhp, zfs_iter_f func, void *data) { nvlist_t *nvl = zfs_get_clones_nvl(zhp); diff --git a/lib/libzfs/libzfs_mount.c b/lib/libzfs/libzfs_mount.c index 4123968b0..552fddea7 100644 --- a/lib/libzfs/libzfs_mount.c +++ b/lib/libzfs/libzfs_mount.c @@ -822,7 +822,7 @@ zfs_unshare_smb(zfs_handle_t *zhp, const char *mountpoint) /* * Same as zfs_unmountall(), but for NFS and SMB unshares. */ -int +static int zfs_unshareall_proto(zfs_handle_t *zhp, zfs_share_proto_t *proto) { prop_changelist_t *clp; diff --git a/lib/libzfs/libzfs_pool.c b/lib/libzfs/libzfs_pool.c index 96ac42622..11b3d4cd9 100644 --- a/lib/libzfs/libzfs_pool.c +++ b/lib/libzfs/libzfs_pool.c @@ -445,7 +445,7 @@ bootfs_name_valid(const char *pool, const char *bootfs) return (B_FALSE); } -boolean_t +static boolean_t zpool_is_bootable(zpool_handle_t *zhp) { char bootfs[ZFS_MAX_DATASET_NAME_LEN]; @@ -2141,7 +2141,7 @@ xlate_init_err(int err) * Begin, suspend, or cancel the initialization (initializing of all free * blocks) for the given vdevs in the given pool. */ -int +static int zpool_initialize_impl(zpool_handle_t *zhp, pool_initialize_func_t cmd_type, nvlist_t *vds, boolean_t wait) { diff --git a/lib/libzfs/libzfs_sendrecv.c b/lib/libzfs/libzfs_sendrecv.c index 3fffc426c..097766c19 100644 --- a/lib/libzfs/libzfs_sendrecv.c +++ b/lib/libzfs/libzfs_sendrecv.c @@ -2296,7 +2296,7 @@ err_out: return (err); } -zfs_handle_t * +static zfs_handle_t * name_to_dir_handle(libzfs_handle_t *hdl, const char *snapname) { char dirname[ZFS_MAX_DATASET_NAME_LEN]; @@ -2877,7 +2877,7 @@ typedef struct guid_to_name_data { uint64_t num_redact_snaps; } guid_to_name_data_t; -boolean_t +static boolean_t redact_snaps_match(zfs_handle_t *zhp, guid_to_name_data_t *gtnd) { uint64_t *bmark_snaps; diff --git a/lib/libzfs/libzfs_util.c b/lib/libzfs/libzfs_util.c index cb96d8da8..e8ef40e5a 100644 --- a/lib/libzfs/libzfs_util.c +++ b/lib/libzfs/libzfs_util.c @@ -1773,7 +1773,7 @@ typedef struct expand_data { zfs_type_t type; } expand_data_t; -int +static int zprop_expand_list_cb(int prop, void *cb) { zprop_list_t *entry; |