提交 ecda0de3 编写于 作者: C Chao Yu 提交者: Jaegeuk Kim

f2fs: add a tracepoint for f2fs_write_{meta,node,data}_page

This patch adds a tracepoint for f2fs_write_{meta,node,data}_page to trace when
page is writting out.
Signed-off-by: NChao Yu <chao2.yu@samsung.com>
Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
上级 dfb2bf38
......@@ -157,6 +157,8 @@ static int f2fs_write_meta_page(struct page *page,
struct inode *inode = page->mapping->host;
struct f2fs_sb_info *sbi = F2FS_SB(inode->i_sb);
trace_f2fs_writepage(page, META);
if (unlikely(sbi->por_doing))
goto redirty_out;
if (wbc->for_reclaim)
......
......@@ -788,6 +788,8 @@ static int f2fs_write_data_page(struct page *page,
.rw = (wbc->sync_mode == WB_SYNC_ALL) ? WRITE_SYNC : WRITE,
};
trace_f2fs_writepage(page, DATA);
if (page->index < end_index)
goto write;
......
......@@ -1199,6 +1199,8 @@ static int f2fs_write_node_page(struct page *page,
.rw = (wbc->sync_mode == WB_SYNC_ALL) ? WRITE_SYNC : WRITE,
};
trace_f2fs_writepage(page, NODE);
if (unlikely(sbi->por_doing))
goto redirty_out;
......
......@@ -751,6 +751,13 @@ DECLARE_EVENT_CLASS(f2fs__page,
__entry->dirty)
);
DEFINE_EVENT(f2fs__page, f2fs_writepage,
TP_PROTO(struct page *page, int type),
TP_ARGS(page, type)
);
DEFINE_EVENT(f2fs__page, f2fs_set_page_dirty,
TP_PROTO(struct page *page, int type),
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册