diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2015-03-27 16:18:07 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2015-04-08 09:40:00 -0400 |
commit | 5511b9a471f3bb2f1cd5d7bf6b4191403e49315e (patch) | |
tree | 1ca42206a40fd328591832c58e92aa0983e92ae4 /include/trace | |
parent | 56e1b226088b07d14ad863bb73753ae24d48c113 (diff) |
f2fs: Export the enums in the tracepoints to userspace
The tracepoints that use __print_symbolic() use enums as the value
to convert to strings. Unfortunately, the format files for these
tracepoints show the enum name and not their value. This causes some
userspace tools not to know how to convert __print_symbolic() to
their strings.
Add TRACE_DEFINE_ENUM() macros to export the enums used to userspace
to let those tools know what those enum values are.
Link: http://lkml.kernel.org/r/20150403013802.220157513@goodmis.org
Cc: Namjae Jeon <namjae.jeon@samsung.com>
Cc: Pankaj Kumar <pankaj.km@samsung.com>
Cc: Jaegeuk Kim <jaegeuk@kernel.org>
Reviewed-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'include/trace')
-rw-r--r-- | include/trace/events/f2fs.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/include/trace/events/f2fs.h b/include/trace/events/f2fs.h index 5422dbfaf97d..36f4536b6149 100644 --- a/include/trace/events/f2fs.h +++ b/include/trace/events/f2fs.h | |||
@@ -9,6 +9,36 @@ | |||
9 | #define show_dev(entry) MAJOR(entry->dev), MINOR(entry->dev) | 9 | #define show_dev(entry) MAJOR(entry->dev), MINOR(entry->dev) |
10 | #define show_dev_ino(entry) show_dev(entry), (unsigned long)entry->ino | 10 | #define show_dev_ino(entry) show_dev(entry), (unsigned long)entry->ino |
11 | 11 | ||
12 | TRACE_DEFINE_ENUM(NODE); | ||
13 | TRACE_DEFINE_ENUM(DATA); | ||
14 | TRACE_DEFINE_ENUM(META); | ||
15 | TRACE_DEFINE_ENUM(META_FLUSH); | ||
16 | TRACE_DEFINE_ENUM(CURSEG_HOT_DATA); | ||
17 | TRACE_DEFINE_ENUM(CURSEG_WARM_DATA); | ||
18 | TRACE_DEFINE_ENUM(CURSEG_COLD_DATA); | ||
19 | TRACE_DEFINE_ENUM(CURSEG_HOT_NODE); | ||
20 | TRACE_DEFINE_ENUM(CURSEG_WARM_NODE); | ||
21 | TRACE_DEFINE_ENUM(CURSEG_COLD_NODE); | ||
22 | TRACE_DEFINE_ENUM(NO_CHECK_TYPE); | ||
23 | TRACE_DEFINE_ENUM(GC_GREEDY); | ||
24 | TRACE_DEFINE_ENUM(GC_CB); | ||
25 | TRACE_DEFINE_ENUM(FG_GC); | ||
26 | TRACE_DEFINE_ENUM(BG_GC); | ||
27 | TRACE_DEFINE_ENUM(LFS); | ||
28 | TRACE_DEFINE_ENUM(SSR); | ||
29 | TRACE_DEFINE_ENUM(__REQ_RAHEAD); | ||
30 | TRACE_DEFINE_ENUM(__REQ_WRITE); | ||
31 | TRACE_DEFINE_ENUM(__REQ_SYNC); | ||
32 | TRACE_DEFINE_ENUM(__REQ_NOIDLE); | ||
33 | TRACE_DEFINE_ENUM(__REQ_FLUSH); | ||
34 | TRACE_DEFINE_ENUM(__REQ_FUA); | ||
35 | TRACE_DEFINE_ENUM(__REQ_PRIO); | ||
36 | TRACE_DEFINE_ENUM(__REQ_META); | ||
37 | TRACE_DEFINE_ENUM(CP_UMOUNT); | ||
38 | TRACE_DEFINE_ENUM(CP_FASTBOOT); | ||
39 | TRACE_DEFINE_ENUM(CP_SYNC); | ||
40 | TRACE_DEFINE_ENUM(CP_DISCARD); | ||
41 | |||
12 | #define show_block_type(type) \ | 42 | #define show_block_type(type) \ |
13 | __print_symbolic(type, \ | 43 | __print_symbolic(type, \ |
14 | { NODE, "NODE" }, \ | 44 | { NODE, "NODE" }, \ |