summaryrefslogtreecommitdiffstats
path: root/include/trace
diff options
context:
space:
mode:
authorLukas Czerner <lczerner@redhat.com>2014-02-22 06:18:17 -0500
committerTheodore Ts'o <tytso@mit.edu>2014-02-22 06:18:17 -0500
commita633f5a319cf4116d977e25fea2830dce23a8e74 (patch)
tree0de41a25ba9e750458a72c195229375bc08a7400 /include/trace
parenta9b8241594adda0a7a4fb3b87bf29d2dff0d997d (diff)
downloadop-kernel-dev-a633f5a319cf4116d977e25fea2830dce23a8e74.zip
op-kernel-dev-a633f5a319cf4116d977e25fea2830dce23a8e74.tar.gz
ext4: translate fallocate mode bits to strings
Signed-off-by: Lukas Czerner <lczerner@redhat.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/ext4.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/include/trace/events/ext4.h b/include/trace/events/ext4.h
index 197d312..451e020 100644
--- a/include/trace/events/ext4.h
+++ b/include/trace/events/ext4.h
@@ -68,6 +68,11 @@ struct extent_status;
{ EXTENT_STATUS_DELAYED, "D" }, \
{ EXTENT_STATUS_HOLE, "H" })
+#define show_falloc_mode(mode) __print_flags(mode, "|", \
+ { FALLOC_FL_KEEP_SIZE, "KEEP_SIZE"}, \
+ { FALLOC_FL_PUNCH_HOLE, "PUNCH_HOLE"}, \
+ { FALLOC_FL_NO_HIDE_STALE, "NO_HIDE_STALE"})
+
TRACE_EVENT(ext4_free_inode,
TP_PROTO(struct inode *inode),
@@ -1349,10 +1354,10 @@ TRACE_EVENT(ext4_fallocate_enter,
__entry->mode = mode;
),
- TP_printk("dev %d,%d ino %lu pos %lld len %lld mode %d",
+ TP_printk("dev %d,%d ino %lu pos %lld len %lld mode %s",
MAJOR(__entry->dev), MINOR(__entry->dev),
(unsigned long) __entry->ino, __entry->pos,
- __entry->len, __entry->mode)
+ __entry->len, show_falloc_mode(__entry->mode))
);
TRACE_EVENT(ext4_fallocate_exit,
OpenPOWER on IntegriCloud