summaryrefslogtreecommitdiff
path: root/fs/gfs2/trace_gfs2.h
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2011-04-18 17:18:38 +0400
committerSteven Whitehouse <swhiteho@redhat.com>2011-04-20 12:01:58 +0400
commitc83ae9cad8776bab153a05cc466be39f14011091 (patch)
treeb8ae7e94b03e3e6d21df24ff41d466ea552b6ccb /fs/gfs2/trace_gfs2.h
parent4667a0ec32867865fd4deccf834594b3ea831baf (diff)
downloadlinux-c83ae9cad8776bab153a05cc466be39f14011091.tar.xz
GFS2: Add an AIL writeback tracepoint
Add a tracepoint for monitoring writeback of the AIL. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/trace_gfs2.h')
-rw-r--r--fs/gfs2/trace_gfs2.h28
1 files changed, 28 insertions, 0 deletions
diff --git a/fs/gfs2/trace_gfs2.h b/fs/gfs2/trace_gfs2.h
index 9133d0aaac26..5d07609ec57d 100644
--- a/fs/gfs2/trace_gfs2.h
+++ b/fs/gfs2/trace_gfs2.h
@@ -10,6 +10,7 @@
#include <linux/buffer_head.h>
#include <linux/dlmconstants.h>
#include <linux/gfs2_ondisk.h>
+#include <linux/writeback.h>
#include "incore.h"
#include "glock.h"
@@ -320,6 +321,33 @@ TRACE_EVENT(gfs2_log_blocks,
MINOR(__entry->dev), __entry->blocks)
);
+/* Writing back the AIL */
+TRACE_EVENT(gfs2_ail_flush,
+
+ TP_PROTO(const struct gfs2_sbd *sdp, const struct writeback_control *wbc, int start),
+
+ TP_ARGS(sdp, wbc, start),
+
+ TP_STRUCT__entry(
+ __field( dev_t, dev )
+ __field( int, start )
+ __field( int, sync_mode )
+ __field( long, nr_to_write )
+ ),
+
+ TP_fast_assign(
+ __entry->dev = sdp->sd_vfs->s_dev;
+ __entry->start = start;
+ __entry->sync_mode = wbc->sync_mode;
+ __entry->nr_to_write = wbc->nr_to_write;
+ ),
+
+ TP_printk("%u,%u ail flush %s %s %ld", MAJOR(__entry->dev),
+ MINOR(__entry->dev), __entry->start ? "start" : "end",
+ __entry->sync_mode == WB_SYNC_ALL ? "all" : "none",
+ __entry->nr_to_write)
+);
+
/* Section 3 - bmap
*
* Objectives: