diff options
author | George Melikov <[email protected]> | 2017-01-12 20:42:11 +0300 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2017-01-12 09:42:11 -0800 |
commit | e9aa730c49b91694b146e0cd28192f1aaf843d0e (patch) | |
tree | 3ee2eaf10960ad98e5f5feaee05074db0f2876d5 /module | |
parent | 42b64e50c093a4ad499458a6258254e399a4de52 (diff) |
OpenZFS 6328 - Fix cstyle errors in zfs codebase
Authored by: Paul Dagnelie <[email protected]>
Reviewed by: Matthew Ahrens <[email protected]>
Reviewed by: Alex Reece <[email protected]>
Reviewed by: Richard Elling <[email protected]>
Reviewed by: Jorgen Lundman <[email protected]>
Approved by: Robert Mustacchi <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Ported-by: George Melikov <[email protected]>
OpenZFS-issue: https://www.illumos.org/issues/6328
OpenZFS-commit: https://github.com/illumos/illumos-gate/commit/9a686fb
Closes #5579
Diffstat (limited to 'module')
-rw-r--r-- | module/zfs/dsl_dataset.c | 2 | ||||
-rw-r--r-- | module/zfs/space_reftree.c | 4 | ||||
-rw-r--r-- | module/zfs/vdev_label.c | 6 | ||||
-rw-r--r-- | module/zfs/zap_leaf.c | 4 | ||||
-rw-r--r-- | module/zfs/zfeature.c | 6 | ||||
-rw-r--r-- | module/zfs/zfeature_common.c | 3 | ||||
-rw-r--r-- | module/zfs/zfs_dir.c | 4 | ||||
-rw-r--r-- | module/zfs/zfs_ioctl.c | 2 | ||||
-rw-r--r-- | module/zfs/zfs_log.c | 13 | ||||
-rw-r--r-- | module/zfs/zfs_replay.c | 4 | ||||
-rw-r--r-- | module/zfs/zio.c | 6 | ||||
-rw-r--r-- | module/zfs/zrlock.c | 12 |
12 files changed, 31 insertions, 35 deletions
diff --git a/module/zfs/dsl_dataset.c b/module/zfs/dsl_dataset.c index 8abb510e8..c09f19137 100644 --- a/module/zfs/dsl_dataset.c +++ b/module/zfs/dsl_dataset.c @@ -3550,7 +3550,7 @@ dsl_dataset_space_wouldfree(dsl_dataset_t *firstsnap, */ boolean_t dsl_dataset_is_before(dsl_dataset_t *later, dsl_dataset_t *earlier, - uint64_t earlier_txg) + uint64_t earlier_txg) { dsl_pool_t *dp = later->ds_dir->dd_pool; int error; diff --git a/module/zfs/space_reftree.c b/module/zfs/space_reftree.c index efbf95099..038572b08 100644 --- a/module/zfs/space_reftree.c +++ b/module/zfs/space_reftree.c @@ -23,7 +23,7 @@ * Use is subject to license terms. */ /* - * Copyright (c) 2013 by Delphix. All rights reserved. + * Copyright (c) 2013, 2015 by Delphix. All rights reserved. */ #include <sys/zfs_context.h> @@ -97,7 +97,7 @@ space_reftree_add_node(avl_tree_t *t, uint64_t offset, int64_t refcnt) void space_reftree_add_seg(avl_tree_t *t, uint64_t start, uint64_t end, - int64_t refcnt) + int64_t refcnt) { space_reftree_add_node(t, start, refcnt); space_reftree_add_node(t, end, -refcnt); diff --git a/module/zfs/vdev_label.c b/module/zfs/vdev_label.c index 7a3a0e8a0..54c54237b 100644 --- a/module/zfs/vdev_label.c +++ b/module/zfs/vdev_label.c @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2013 by Delphix. All rights reserved. + * Copyright (c) 2012, 2015 by Delphix. All rights reserved. */ /* @@ -180,7 +180,7 @@ vdev_label_number(uint64_t psize, uint64_t offset) static void vdev_label_read(zio_t *zio, vdev_t *vd, int l, abd_t *buf, uint64_t offset, - uint64_t size, zio_done_func_t *done, void *private, int flags) + uint64_t size, zio_done_func_t *done, void *private, int flags) { ASSERT(spa_config_held(zio->io_spa, SCL_STATE_ALL, RW_WRITER) == SCL_STATE_ALL); @@ -194,7 +194,7 @@ vdev_label_read(zio_t *zio, vdev_t *vd, int l, abd_t *buf, uint64_t offset, static void vdev_label_write(zio_t *zio, vdev_t *vd, int l, abd_t *buf, uint64_t offset, - uint64_t size, zio_done_func_t *done, void *private, int flags) + uint64_t size, zio_done_func_t *done, void *private, int flags) { ASSERT(spa_config_held(zio->io_spa, SCL_ALL, RW_WRITER) == SCL_ALL || (spa_config_held(zio->io_spa, SCL_CONFIG | SCL_STATE, RW_READER) == diff --git a/module/zfs/zap_leaf.c b/module/zfs/zap_leaf.c index 3abc08cff..c9837981d 100644 --- a/module/zfs/zap_leaf.c +++ b/module/zfs/zap_leaf.c @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2013, 2014 by Delphix. All rights reserved. + * Copyright (c) 2013, 2015 by Delphix. All rights reserved. */ /* @@ -538,7 +538,7 @@ zap_entry_read_name(zap_t *zap, const zap_entry_handle_t *zeh, uint16_t buflen, int zap_entry_update(zap_entry_handle_t *zeh, - uint8_t integer_size, uint64_t num_integers, const void *buf) + uint8_t integer_size, uint64_t num_integers, const void *buf) { int delta_chunks; zap_leaf_t *l = zeh->zeh_leaf; diff --git a/module/zfs/zfeature.c b/module/zfs/zfeature.c index bda954829..d8220aa23 100644 --- a/module/zfs/zfeature.c +++ b/module/zfs/zfeature.c @@ -277,7 +277,8 @@ feature_get_refcount_from_disk(spa_t *spa, zfeature_info_t *feature, static int -feature_get_enabled_txg(spa_t *spa, zfeature_info_t *feature, uint64_t *res) { +feature_get_enabled_txg(spa_t *spa, zfeature_info_t *feature, uint64_t *res) +{ ASSERTV(uint64_t enabled_txg_obj = spa->spa_feat_enabled_txg_obj); ASSERT(zfeature_depends_on(feature->fi_feature, @@ -500,7 +501,8 @@ spa_feature_is_active(spa_t *spa, spa_feature_t fid) * Returns B_FALSE otherwise (i.e. if the feature is not enabled). */ boolean_t -spa_feature_enabled_txg(spa_t *spa, spa_feature_t fid, uint64_t *txg) { +spa_feature_enabled_txg(spa_t *spa, spa_feature_t fid, uint64_t *txg) +{ int err; ASSERT(VALID_FEATURE_FID(fid)); diff --git a/module/zfs/zfeature_common.c b/module/zfs/zfeature_common.c index ccd65a7b7..0459d4521 100644 --- a/module/zfs/zfeature_common.c +++ b/module/zfs/zfeature_common.c @@ -122,7 +122,8 @@ zfeature_lookup_name(const char *name, spa_feature_t *res) } boolean_t -zfeature_depends_on(spa_feature_t fid, spa_feature_t check) { +zfeature_depends_on(spa_feature_t fid, spa_feature_t check) +{ zfeature_info_t *feature = &spa_feature_table[fid]; int i; diff --git a/module/zfs/zfs_dir.c b/module/zfs/zfs_dir.c index c28b85c98..b66a9b364 100644 --- a/module/zfs/zfs_dir.c +++ b/module/zfs/zfs_dir.c @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2013, 2014 by Delphix. All rights reserved. + * Copyright (c) 2013, 2015 by Delphix. All rights reserved. */ @@ -838,7 +838,7 @@ zfs_dropname(zfs_dirlock_t *dl, znode_t *zp, znode_t *dzp, dmu_tx_t *tx, */ int zfs_link_destroy(zfs_dirlock_t *dl, znode_t *zp, dmu_tx_t *tx, int flag, - boolean_t *unlinkedp) + boolean_t *unlinkedp) { znode_t *dzp = dl->dl_dzp; zfs_sb_t *zsb = ZTOZSB(dzp); diff --git a/module/zfs/zfs_ioctl.c b/module/zfs/zfs_ioctl.c index 98ab745f8..439134dec 100644 --- a/module/zfs/zfs_ioctl.c +++ b/module/zfs/zfs_ioctl.c @@ -5767,7 +5767,7 @@ zfs_ioctl_register_dataset_read(zfs_ioc_t ioc, zfs_ioc_legacy_func_t *func) static void zfs_ioctl_register_dataset_modify(zfs_ioc_t ioc, zfs_ioc_legacy_func_t *func, - zfs_secpolicy_func_t *secpolicy) + zfs_secpolicy_func_t *secpolicy) { zfs_ioctl_register_legacy(ioc, func, secpolicy, DATASET_NAME, B_TRUE, POOL_CHECK_SUSPENDED | POOL_CHECK_READONLY); diff --git a/module/zfs/zfs_log.c b/module/zfs/zfs_log.c index 8bb8b0a97..ca3699052 100644 --- a/module/zfs/zfs_log.c +++ b/module/zfs/zfs_log.c @@ -20,6 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015 by Delphix. All rights reserved. */ @@ -374,7 +375,7 @@ zfs_log_create(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, */ void zfs_log_remove(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, - znode_t *dzp, char *name, uint64_t foid) + znode_t *dzp, char *name, uint64_t foid) { itx_t *itx; lr_remove_t *lr; @@ -398,7 +399,7 @@ zfs_log_remove(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, */ void zfs_log_link(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, - znode_t *dzp, znode_t *zp, char *name) + znode_t *dzp, znode_t *zp, char *name) { itx_t *itx; lr_link_t *lr; @@ -453,7 +454,7 @@ zfs_log_symlink(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, */ void zfs_log_rename(zilog_t *zilog, dmu_tx_t *tx, uint64_t txtype, - znode_t *sdzp, char *sname, znode_t *tdzp, char *dname, znode_t *szp) + znode_t *sdzp, char *sname, znode_t *tdzp, char *dname, znode_t *szp) { itx_t *itx; lr_rename_t *lr; @@ -483,8 +484,8 @@ long zfs_immediate_write_sz = 32768; void zfs_log_write(zilog_t *zilog, dmu_tx_t *tx, int txtype, - znode_t *zp, offset_t off, ssize_t resid, int ioflag, - zil_callback_t callback, void *callback_data) + znode_t *zp, offset_t off, ssize_t resid, int ioflag, + zil_callback_t callback, void *callback_data) { itx_wr_state_t write_state; boolean_t slogging; @@ -567,7 +568,7 @@ zfs_log_write(zilog_t *zilog, dmu_tx_t *tx, int txtype, */ void zfs_log_truncate(zilog_t *zilog, dmu_tx_t *tx, int txtype, - znode_t *zp, uint64_t off, uint64_t len) + znode_t *zp, uint64_t off, uint64_t len) { itx_t *itx; lr_truncate_t *lr; diff --git a/module/zfs/zfs_replay.c b/module/zfs/zfs_replay.c index 19387ce05..1e72745f0 100644 --- a/module/zfs/zfs_replay.c +++ b/module/zfs/zfs_replay.c @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012 Cyril Plisko. All rights reserved. - * Copyright (c) 2013 by Delphix. All rights reserved. + * Copyright (c) 2013, 2015 by Delphix. All rights reserved. */ #include <sys/types.h> @@ -58,7 +58,7 @@ static void zfs_init_vattr(vattr_t *vap, uint64_t mask, uint64_t mode, - uint64_t uid, uint64_t gid, uint64_t rdev, uint64_t nodeid) + uint64_t uid, uint64_t gid, uint64_t rdev, uint64_t nodeid) { bzero(vap, sizeof (*vap)); vap->va_mask = (uint_t)mask; diff --git a/module/zfs/zio.c b/module/zfs/zio.c index a242c6bf6..6f906b909 100644 --- a/module/zfs/zio.c +++ b/module/zfs/zio.c @@ -317,7 +317,7 @@ zio_data_buf_free(void *buf, size_t size) */ void zio_push_transform(zio_t *zio, abd_t *data, uint64_t size, uint64_t bufsize, - zio_transform_func_t *transform) + zio_transform_func_t *transform) { zio_transform_t *zt = kmem_alloc(sizeof (zio_transform_t), KM_SLEEP); @@ -1108,8 +1108,8 @@ zio_vdev_child_io(zio_t *pio, blkptr_t *bp, vdev_t *vd, uint64_t offset, zio_t * zio_vdev_delegated_io(vdev_t *vd, uint64_t offset, abd_t *data, uint64_t size, - int type, zio_priority_t priority, enum zio_flag flags, - zio_done_func_t *done, void *private) + int type, zio_priority_t priority, enum zio_flag flags, + zio_done_func_t *done, void *private) { zio_t *zio; diff --git a/module/zfs/zrlock.c b/module/zfs/zrlock.c index 52f9ee839..137875fe0 100644 --- a/module/zfs/zrlock.c +++ b/module/zfs/zrlock.c @@ -70,11 +70,7 @@ zrl_destroy(zrlock_t *zrl) } void -#ifdef ZFS_DEBUG -zrl_add_debug(zrlock_t *zrl, const char *zc) -#else -zrl_add(zrlock_t *zrl) -#endif +zrl_add_impl(zrlock_t *zrl, const char *zc) { uint32_t n = (uint32_t)zrl->zr_refcount; @@ -199,11 +195,7 @@ zrl_owner(zrlock_t *zrl) #if defined(_KERNEL) && defined(HAVE_SPL) -#ifdef ZFS_DEBUG -EXPORT_SYMBOL(zrl_add_debug); -#else -EXPORT_SYMBOL(zrl_add); -#endif +EXPORT_SYMBOL(zrl_add_impl); EXPORT_SYMBOL(zrl_remove); #endif |