scoutfs: replace trace_printk in compact.c

Signed-off-by: Mark Fasheh <mfasheh@versity.com>
This commit is contained in:
Mark Fasheh
2017-09-20 16:01:31 -05:00
committed by Mark Fasheh
parent 3a5093c6ae
commit 2c1f117bef
2 changed files with 19 additions and 1 deletions

View File

@@ -618,7 +618,7 @@ static void scoutfs_compact_func(struct work_struct *work)
free_cseg_list(sb, &results);
WARN_ON_ONCE(ret);
trace_printk("ret %d\n", ret);
trace_scoutfs_compact_func(sb, ret);
}
void scoutfs_compact_kick(struct super_block *sb)

View File

@@ -36,6 +36,24 @@
#define FSID_ARG(sb) le64_to_cpu(SCOUTFS_SB(sb)->super.hdr.fsid)
#define FSID_FMT "%llx"
TRACE_EVENT(scoutfs_compact_func,
TP_PROTO(struct super_block *sb, int ret),
TP_ARGS(sb, ret),
TP_STRUCT__entry(
__field(__u64, fsid)
__field(int, ret)
),
TP_fast_assign(
__entry->fsid = FSID_ARG(sb);
__entry->ret = ret;
),
TP_printk(FSID_FMT" ret %d", __entry->fsid, __entry->ret)
);
TRACE_EVENT(scoutfs_alloc_free,
TP_PROTO(struct super_block *sb, __u64 segno, __u64 index, int nr,
int ret),