mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
Clean up CSTYLEDs
69 CSTYLED BEGINs remain, appx. 30 of which can be removed if cstyle(1) had a useful policy regarding CALL(ARG1, ARG2, ARG3); above 2 lines. As it stands, it spits out *both* sysctl_os.c: 385: continuation line should be indented by 4 spaces sysctl_os.c: 385: indent by spaces instead of tabs which is very cool Another >10 could be fixed by removing "ulong" &al. handling. I don't foresee anyone actually using it intentionally (does it even exist in modern headers? why did it in the first place?). Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Closes #12993
This commit is contained in:
@@ -135,12 +135,10 @@ DECLARE_EVENT_CLASS(zfs_ace_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ACE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_ace_class, name, \
|
||||
TP_PROTO(znode_t *zn, zfs_ace_hdr_t *ace, uint32_t mask_matched), \
|
||||
TP_ARGS(zn, ace, mask_matched))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(znode_t *zn, zfs_ace_hdr_t *ace, uint32_t mask_matched), \
|
||||
TP_ARGS(zn, ace, mask_matched))
|
||||
DEFINE_ACE_EVENT(zfs_zfs__ace__denies);
|
||||
DEFINE_ACE_EVENT(zfs_zfs__ace__allows);
|
||||
|
||||
|
||||
@@ -98,12 +98,10 @@ DECLARE_EVENT_CLASS(zfs_arc_buf_hdr_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ARC_BUF_HDR_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_arc_buf_hdr_class, name, \
|
||||
TP_PROTO(arc_buf_hdr_t *ab), \
|
||||
TP_ARGS(ab))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(arc_buf_hdr_t *ab), \
|
||||
TP_ARGS(ab))
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__hit);
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__evict);
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__delete);
|
||||
@@ -143,12 +141,10 @@ DECLARE_EVENT_CLASS(zfs_l2arc_rw_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_L2ARC_RW_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_l2arc_rw_class, name, \
|
||||
TP_PROTO(vdev_t *vd, zio_t *zio), \
|
||||
TP_ARGS(vd, zio))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(vdev_t *vd, zio_t *zio), \
|
||||
TP_ARGS(vd, zio))
|
||||
DEFINE_L2ARC_RW_EVENT(zfs_l2arc__read);
|
||||
DEFINE_L2ARC_RW_EVENT(zfs_l2arc__write);
|
||||
|
||||
@@ -170,12 +166,10 @@ DECLARE_EVENT_CLASS(zfs_l2arc_iodone_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_L2ARC_IODONE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_l2arc_iodone_class, name, \
|
||||
TP_PROTO(zio_t *zio, l2arc_write_callback_t *cb), \
|
||||
TP_ARGS(zio, cb))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(zio_t *zio, l2arc_write_callback_t *cb), \
|
||||
TP_ARGS(zio, cb))
|
||||
DEFINE_L2ARC_IODONE_EVENT(zfs_l2arc__iodone);
|
||||
|
||||
|
||||
@@ -284,13 +278,11 @@ DECLARE_EVENT_CLASS(zfs_arc_miss_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ARC_MISS_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_arc_miss_class, name, \
|
||||
TP_PROTO(arc_buf_hdr_t *hdr, \
|
||||
const blkptr_t *bp, uint64_t size, const zbookmark_phys_t *zb), \
|
||||
TP_ARGS(hdr, bp, size, zb))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(arc_buf_hdr_t *hdr, \
|
||||
const blkptr_t *bp, uint64_t size, const zbookmark_phys_t *zb), \
|
||||
TP_ARGS(hdr, bp, size, zb))
|
||||
DEFINE_ARC_MISS_EVENT(zfs_arc__miss);
|
||||
|
||||
/*
|
||||
@@ -345,13 +337,10 @@ DECLARE_EVENT_CLASS(zfs_l2arc_evict_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_L2ARC_EVICT_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_l2arc_evict_class, name, \
|
||||
TP_PROTO(l2arc_dev_t *dev, \
|
||||
list_t *buflist, uint64_t taddr, boolean_t all), \
|
||||
TP_ARGS(dev, buflist, taddr, all))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(l2arc_dev_t *dev, list_t *buflist, uint64_t taddr, boolean_t all),\
|
||||
TP_ARGS(dev, buflist, taddr, all))
|
||||
DEFINE_L2ARC_EVICT_EVENT(zfs_l2arc__evict);
|
||||
|
||||
/*
|
||||
@@ -381,12 +370,10 @@ DECLARE_EVENT_CLASS(zfs_arc_wait_for_eviction_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ARC_WAIT_FOR_EVICTION_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_arc_wait_for_eviction_class, name, \
|
||||
TP_PROTO(uint64_t amount, uint64_t arc_evict_count, uint64_t aew_count), \
|
||||
TP_ARGS(amount, arc_evict_count, aew_count))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(uint64_t amount, uint64_t arc_evict_count, uint64_t aew_count), \
|
||||
TP_ARGS(amount, arc_evict_count, aew_count))
|
||||
DEFINE_ARC_WAIT_FOR_EVICTION_EVENT(zfs_arc__wait__for__eviction);
|
||||
|
||||
#endif /* _TRACE_ARC_H */
|
||||
|
||||
@@ -65,12 +65,10 @@ DECLARE_EVENT_CLASS(zfs_dprintf_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DPRINTF_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_dprintf_class, name, \
|
||||
TP_PROTO(const char *msg), \
|
||||
TP_ARGS(msg))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(const char *msg), \
|
||||
TP_ARGS(msg))
|
||||
DEFINE_DPRINTF_EVENT(zfs_zfs__dprintf);
|
||||
|
||||
#endif /* _TRACE_DBGMSG_H */
|
||||
|
||||
@@ -117,20 +117,16 @@ DECLARE_EVENT_CLASS(zfs_dbuf_state_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DBUF_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_dbuf_class, name, \
|
||||
TP_PROTO(dmu_buf_impl_t *db, zio_t *zio), \
|
||||
TP_ARGS(db, zio))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dmu_buf_impl_t *db, zio_t *zio), \
|
||||
TP_ARGS(db, zio))
|
||||
DEFINE_DBUF_EVENT(zfs_blocked__read);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DBUF_STATE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_dbuf_state_class, name, \
|
||||
TP_PROTO(dmu_buf_impl_t *db, const char *why), \
|
||||
TP_ARGS(db, why))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dmu_buf_impl_t *db, const char *why), \
|
||||
TP_ARGS(db, why))
|
||||
DEFINE_DBUF_STATE_EVENT(zfs_dbuf__state_change);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
@@ -143,12 +139,10 @@ DECLARE_EVENT_CLASS(zfs_dbuf_evict_one_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DBUF_EVICT_ONE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_dbuf_evict_one_class, name, \
|
||||
TP_PROTO(dmu_buf_impl_t *db, multilist_sublist_t *mls), \
|
||||
TP_ARGS(db, mls))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dmu_buf_impl_t *db, multilist_sublist_t *mls), \
|
||||
TP_ARGS(db, mls))
|
||||
DEFINE_DBUF_EVICT_ONE_EVENT(zfs_dbuf__evict__one);
|
||||
|
||||
#endif /* _TRACE_DBUF_H */
|
||||
|
||||
@@ -81,12 +81,10 @@ DECLARE_EVENT_CLASS(zfs_delay_mintime_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DELAY_MINTIME_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_delay_mintime_class, name, \
|
||||
TP_PROTO(dmu_tx_t *tx, uint64_t dirty, uint64_t min_tx_time), \
|
||||
TP_ARGS(tx, dirty, min_tx_time))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dmu_tx_t *tx, uint64_t dirty, uint64_t min_tx_time), \
|
||||
TP_ARGS(tx, dirty, min_tx_time))
|
||||
DEFINE_DELAY_MINTIME_EVENT(zfs_delay__mintime);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
@@ -110,13 +108,11 @@ DECLARE_EVENT_CLASS(zfs_free_long_range_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_FREE_LONG_RANGE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_free_long_range_class, name, \
|
||||
TP_PROTO(uint64_t long_free_dirty_all_txgs, \
|
||||
uint64_t chunk_len, uint64_t txg), \
|
||||
TP_ARGS(long_free_dirty_all_txgs, chunk_len, txg))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(uint64_t long_free_dirty_all_txgs, \
|
||||
uint64_t chunk_len, uint64_t txg), \
|
||||
TP_ARGS(long_free_dirty_all_txgs, chunk_len, txg))
|
||||
DEFINE_FREE_LONG_RANGE_EVENT(zfs_free__long__range);
|
||||
|
||||
#endif /* _TRACE_DMU_H */
|
||||
|
||||
@@ -105,12 +105,10 @@ DECLARE_EVENT_CLASS(zfs_dnode_move_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_DNODE_MOVE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_dnode_move_class, name, \
|
||||
TP_PROTO(dnode_t *dn, int64_t refcount, uint32_t dbufs), \
|
||||
TP_ARGS(dn, refcount, dbufs))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dnode_t *dn, int64_t refcount, uint32_t dbufs), \
|
||||
TP_ARGS(dn, refcount, dbufs))
|
||||
DEFINE_DNODE_MOVE_EVENT(zfs_dnode__move);
|
||||
|
||||
#endif /* _TRACE_DNODE_H */
|
||||
|
||||
@@ -63,12 +63,10 @@ DECLARE_EVENT_CLASS(zfs_multilist_insert_remove_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_MULTILIST_INSERT_REMOVE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_multilist_insert_remove_class, name, \
|
||||
TP_PROTO(multilist_t *ml, unsigned int sublist_idx, void *obj), \
|
||||
TP_ARGS(ml, sublist_idx, obj))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(multilist_t *ml, unsigned int sublist_idx, void *obj), \
|
||||
TP_ARGS(ml, sublist_idx, obj))
|
||||
DEFINE_MULTILIST_INSERT_REMOVE_EVENT(zfs_multilist__insert);
|
||||
DEFINE_MULTILIST_INSERT_REMOVE_EVENT(zfs_multilist__remove);
|
||||
|
||||
|
||||
@@ -55,12 +55,10 @@ DECLARE_EVENT_CLASS(zfs_txg_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_TXG_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_txg_class, name, \
|
||||
TP_PROTO(dsl_pool_t *dp, uint64_t txg), \
|
||||
TP_ARGS(dp, txg))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(dsl_pool_t *dp, uint64_t txg), \
|
||||
TP_ARGS(dp, txg))
|
||||
DEFINE_TXG_EVENT(zfs_dsl_pool_sync__done);
|
||||
DEFINE_TXG_EVENT(zfs_txg__quiescing);
|
||||
DEFINE_TXG_EVENT(zfs_txg__opened);
|
||||
|
||||
@@ -68,12 +68,10 @@ DECLARE_EVENT_CLASS(zfs_removing_class_3,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_REMOVE_FREE_EVENT(name) \
|
||||
#define DEFINE_REMOVE_FREE_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_removing_class_3, name, \
|
||||
TP_PROTO(spa_t *spa, uint64_t offset, uint64_t size), \
|
||||
TP_ARGS(spa, offset, size))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(spa_t *spa, uint64_t offset, uint64_t size), \
|
||||
TP_ARGS(spa, offset, size))
|
||||
DEFINE_REMOVE_FREE_EVENT(zfs_remove__free__synced);
|
||||
DEFINE_REMOVE_FREE_EVENT(zfs_remove__free__unvisited);
|
||||
|
||||
@@ -107,12 +105,10 @@ DECLARE_EVENT_CLASS(zfs_removing_class_4,
|
||||
__entry->vdev_size, __entry->vdev_txg)
|
||||
);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_REMOVE_FREE_EVENT_TXG(name) \
|
||||
DEFINE_EVENT(zfs_removing_class_4, name, \
|
||||
TP_PROTO(spa_t *spa, uint64_t offset, uint64_t size,uint64_t txg), \
|
||||
TP_ARGS(spa, offset, size, txg))
|
||||
/* END CSTYLED */
|
||||
TP_PROTO(spa_t *spa, uint64_t offset, uint64_t size,uint64_t txg), \
|
||||
TP_ARGS(spa, offset, size, txg))
|
||||
DEFINE_REMOVE_FREE_EVENT_TXG(zfs_remove__free__inflight);
|
||||
|
||||
#endif /* _TRACE_VDEV_H */
|
||||
|
||||
@@ -170,14 +170,12 @@ DECLARE_EVENT_CLASS(zfs_zil_process_itx_class,
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ZIL_PROCESS_ITX_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_zil_process_itx_class, name, \
|
||||
TP_PROTO(zilog_t *zilog, itx_t *itx), \
|
||||
TP_ARGS(zilog, itx))
|
||||
TP_PROTO(zilog_t *zilog, itx_t *itx), \
|
||||
TP_ARGS(zilog, itx))
|
||||
DEFINE_ZIL_PROCESS_ITX_EVENT(zfs_zil__process__commit__itx);
|
||||
DEFINE_ZIL_PROCESS_ITX_EVENT(zfs_zil__process__normal__itx);
|
||||
/* END CSTYLED */
|
||||
|
||||
/*
|
||||
* Generic support for two argument tracepoints of the form:
|
||||
@@ -203,13 +201,11 @@ DECLARE_EVENT_CLASS(zfs_zil_commit_io_error_class,
|
||||
ZILOG_TP_PRINTK_ARGS, ZCW_TP_PRINTK_ARGS)
|
||||
);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
#define DEFINE_ZIL_COMMIT_IO_ERROR_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_zil_commit_io_error_class, name, \
|
||||
TP_PROTO(zilog_t *zilog, zil_commit_waiter_t *zcw), \
|
||||
TP_ARGS(zilog, zcw))
|
||||
TP_PROTO(zilog_t *zilog, zil_commit_waiter_t *zcw), \
|
||||
TP_ARGS(zilog, zcw))
|
||||
DEFINE_ZIL_COMMIT_IO_ERROR_EVENT(zfs_zil__commit__io__error);
|
||||
/* END CSTYLED */
|
||||
|
||||
#endif /* _TRACE_ZIL_H */
|
||||
|
||||
|
||||
@@ -70,12 +70,12 @@ DECLARE_EVENT_CLASS(zfs_zrlock_class,
|
||||
__entry->refcount, __entry->n)
|
||||
#endif
|
||||
);
|
||||
/* END_CSTYLED */
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_ZRLOCK_EVENT(name) \
|
||||
DEFINE_EVENT(zfs_zrlock_class, name, \
|
||||
TP_PROTO(zrlock_t *zrl, kthread_t *owner, uint32_t n), \
|
||||
TP_ARGS(zrl, owner, n))
|
||||
TP_PROTO(zrlock_t *zrl, kthread_t *owner, uint32_t n), \
|
||||
TP_ARGS(zrl, owner, n))
|
||||
DEFINE_ZRLOCK_EVENT(zfs_zrlock__reentry);
|
||||
|
||||
#endif /* _TRACE_ZRLOCK_H */
|
||||
|
||||
Reference in New Issue
Block a user