summaryrefslogtreecommitdiff
path: root/include/trace/events/f2fs.h
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2019-04-02 13:52:22 +0300
committerJaegeuk Kim <jaegeuk@kernel.org>2019-04-16 23:51:32 +0300
commit126ce7214d213412bd4a23c731626ee7fe4cb4ec (patch)
tree05c024ac1c2dfb3926046922199fccb1a5ffe985 /include/trace/events/f2fs.h
parente1074d4b1deb2d26cca5a4aae765939ead91f551 (diff)
downloadlinux-126ce7214d213412bd4a23c731626ee7fe4cb4ec.tar.xz
f2fs: add tracepoint for f2fs_file_write_iter()
This patch adds tracepoint for f2fs_file_write_iter(). Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'include/trace/events/f2fs.h')
-rw-r--r--include/trace/events/f2fs.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/include/trace/events/f2fs.h b/include/trace/events/f2fs.h
index a3916b4dd57e..353a6fff2b80 100644
--- a/include/trace/events/f2fs.h
+++ b/include/trace/events/f2fs.h
@@ -533,6 +533,37 @@ TRACE_EVENT(f2fs_truncate_partial_nodes,
__entry->err)
);
+TRACE_EVENT(f2fs_file_write_iter,
+
+ TP_PROTO(struct inode *inode, unsigned long offset,
+ unsigned long length, int ret),
+
+ TP_ARGS(inode, offset, length, ret),
+
+ TP_STRUCT__entry(
+ __field(dev_t, dev)
+ __field(ino_t, ino)
+ __field(unsigned long, offset)
+ __field(unsigned long, length)
+ __field(int, ret)
+ ),
+
+ TP_fast_assign(
+ __entry->dev = inode->i_sb->s_dev;
+ __entry->ino = inode->i_ino;
+ __entry->offset = offset;
+ __entry->length = length;
+ __entry->ret = ret;
+ ),
+
+ TP_printk("dev = (%d,%d), ino = %lu, "
+ "offset = %lu, length = %lu, written(err) = %d",
+ show_dev_ino(__entry),
+ __entry->offset,
+ __entry->length,
+ __entry->ret)
+);
+
TRACE_EVENT(f2fs_map_blocks,
TP_PROTO(struct inode *inode, struct f2fs_map_blocks *map, int ret),