mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 10:37:35 +03:00
codebase style improvements for OpenZFS 6459 port
This commit is contained in:
committed by
Brian Behlendorf
parent
ec441a9c53
commit
4ea3f86426
@@ -139,9 +139,11 @@ DECLARE_EVENT_CLASS(zfs_ace_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_ACE_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_ACE_EVENT(zfs_zfs__ace__denies);
|
||||
DEFINE_ACE_EVENT(zfs_zfs__ace__allows);
|
||||
|
||||
|
||||
@@ -98,9 +98,11 @@ DECLARE_EVENT_CLASS(zfs_arc_buf_hdr_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_ARC_BUF_HDR_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_arc_buf_hdr_class, name, \
|
||||
TP_PROTO(arc_buf_hdr_t *ab), \
|
||||
TP_ARGS(ab))
|
||||
/* END CSTYLED */
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__hit);
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__evict);
|
||||
DEFINE_ARC_BUF_HDR_EVENT(zfs_arc__delete);
|
||||
@@ -141,9 +143,11 @@ DECLARE_EVENT_CLASS(zfs_l2arc_rw_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_L2ARC_RW_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_l2arc_rw_class, name, \
|
||||
TP_PROTO(vdev_t *vd, zio_t *zio), \
|
||||
TP_ARGS(vd, zio))
|
||||
/* END CSTYLED */
|
||||
DEFINE_L2ARC_RW_EVENT(zfs_l2arc__read);
|
||||
DEFINE_L2ARC_RW_EVENT(zfs_l2arc__write);
|
||||
|
||||
@@ -166,9 +170,11 @@ DECLARE_EVENT_CLASS(zfs_l2arc_iodone_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_L2ARC_IODONE_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_l2arc_iodone_class, name, \
|
||||
TP_PROTO(zio_t *zio, l2arc_write_callback_t *cb), \
|
||||
TP_ARGS(zio, cb))
|
||||
/* END CSTYLED */
|
||||
DEFINE_L2ARC_IODONE_EVENT(zfs_l2arc__iodone);
|
||||
|
||||
|
||||
@@ -278,10 +284,12 @@ DECLARE_EVENT_CLASS(zfs_arc_miss_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_ARC_MISS_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_ARC_MISS_EVENT(zfs_arc__miss);
|
||||
|
||||
/*
|
||||
@@ -337,10 +345,12 @@ DECLARE_EVENT_CLASS(zfs_l2arc_evict_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_L2ARC_EVICT_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_L2ARC_EVICT_EVENT(zfs_l2arc__evict);
|
||||
|
||||
#endif /* _TRACE_ARC_H */
|
||||
|
||||
@@ -69,10 +69,12 @@ DECLARE_EVENT_CLASS(zfs_dprintf_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_DPRINTF_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_dprintf_class, name, \
|
||||
TP_PROTO(const char *file, const char *function, int line, \
|
||||
const char *msg), \
|
||||
TP_ARGS(file, function, line, msg))
|
||||
/* END CSTYLED */
|
||||
DEFINE_DPRINTF_EVENT(zfs_zfs__dprintf);
|
||||
|
||||
/*
|
||||
@@ -109,16 +111,20 @@ DECLARE_EVENT_CLASS(zfs_set_error_class,
|
||||
|
||||
#ifdef TP_CONDITION
|
||||
#define DEFINE_SET_ERROR_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT_CONDITION(zfs_set_error_class, name, \
|
||||
TP_PROTO(const char *file, const char *function, int line, \
|
||||
uintptr_t error), \
|
||||
TP_ARGS(file, function, line, error), \
|
||||
TP_CONDITION(error))
|
||||
/* END CSTYLED */
|
||||
#else
|
||||
#define DEFINE_SET_ERROR_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_set_error_class, name, \
|
||||
TP_PROTO(const char *file, const char *function, int line, \
|
||||
uintptr_t error), \
|
||||
TP_ARGS(file, function, line, error))
|
||||
/* END CSTYLED */
|
||||
#endif
|
||||
DEFINE_SET_ERROR_EVENT(zfs_set__error);
|
||||
|
||||
@@ -78,6 +78,7 @@
|
||||
__entry->db_blkid, __entry->db_offset, \
|
||||
__entry->db_size, __entry->db_state, __entry->db_holds
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
DECLARE_EVENT_CLASS(zfs_dbuf_class,
|
||||
TP_PROTO(dmu_buf_impl_t *db, zio_t *zio),
|
||||
TP_ARGS(db, zio),
|
||||
@@ -85,13 +86,17 @@ DECLARE_EVENT_CLASS(zfs_dbuf_class,
|
||||
TP_fast_assign(DBUF_TP_FAST_ASSIGN),
|
||||
TP_printk(DBUF_TP_PRINTK_FMT, DBUF_TP_PRINTK_ARGS)
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_DBUF_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_dbuf_class, name, \
|
||||
TP_PROTO(dmu_buf_impl_t *db, zio_t *zio), \
|
||||
TP_ARGS(db, zio))
|
||||
/* END CSTYLED */
|
||||
DEFINE_DBUF_EVENT(zfs_blocked__read);
|
||||
|
||||
/* BEGIN CSTYLED */
|
||||
DECLARE_EVENT_CLASS(zfs_dbuf_evict_one_class,
|
||||
TP_PROTO(dmu_buf_impl_t *db, multilist_sublist_t *mls),
|
||||
TP_ARGS(db, mls),
|
||||
@@ -99,11 +104,14 @@ DECLARE_EVENT_CLASS(zfs_dbuf_evict_one_class,
|
||||
TP_fast_assign(DBUF_TP_FAST_ASSIGN),
|
||||
TP_printk(DBUF_TP_PRINTK_FMT, DBUF_TP_PRINTK_ARGS)
|
||||
);
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_DBUF_EVICT_ONE_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_DBUF_EVICT_ONE_EVENT(zfs_dbuf__evict__one);
|
||||
|
||||
#endif /* _TRACE_DBUF_H */
|
||||
|
||||
@@ -105,9 +105,11 @@ DECLARE_EVENT_CLASS(zfs_delay_mintime_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_DELAY_MINTIME_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_DELAY_MINTIME_EVENT(zfs_delay__mintime);
|
||||
|
||||
#endif /* _TRACE_DMU_H */
|
||||
|
||||
@@ -105,9 +105,11 @@ DECLARE_EVENT_CLASS(zfs_dnode_move_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_DNODE_MOVE_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_DNODE_MOVE_EVENT(zfs_dnode__move);
|
||||
|
||||
#endif /* _TRACE_DNODE_H */
|
||||
|
||||
@@ -63,9 +63,11 @@ DECLARE_EVENT_CLASS(zfs_multilist_insert_remove_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_MULTILIST_INSERT_REMOVE_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
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 */
|
||||
DEFINE_MULTILIST_INSERT_REMOVE_EVENT(zfs_multilist__insert);
|
||||
DEFINE_MULTILIST_INSERT_REMOVE_EVENT(zfs_multilist__remove);
|
||||
|
||||
|
||||
@@ -55,9 +55,11 @@ DECLARE_EVENT_CLASS(zfs_txg_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_TXG_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_txg_class, name, \
|
||||
TP_PROTO(dsl_pool_t *dp, uint64_t txg), \
|
||||
TP_ARGS(dp, txg))
|
||||
/* END CSTYLED */
|
||||
DEFINE_TXG_EVENT(zfs_dsl_pool_sync__done);
|
||||
DEFINE_TXG_EVENT(zfs_txg__quiescing);
|
||||
DEFINE_TXG_EVENT(zfs_txg__opened);
|
||||
|
||||
@@ -114,11 +114,13 @@ DECLARE_EVENT_CLASS(zfs_zil_class,
|
||||
/* END CSTYLED */
|
||||
|
||||
#define DEFINE_ZIL_EVENT(name) \
|
||||
/* BEGIN CSTYLED */
|
||||
DEFINE_EVENT(zfs_zil_class, name, \
|
||||
TP_PROTO(zilog_t *zilog), \
|
||||
TP_ARGS(zilog))
|
||||
DEFINE_ZIL_EVENT(zfs_zil__cw1);
|
||||
DEFINE_ZIL_EVENT(zfs_zil__cw2);
|
||||
/* END CSTYLED */
|
||||
|
||||
#endif /* _TRACE_ZIL_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user