diff options
Diffstat (limited to 'trace-cmd.h')
-rw-r--r-- | trace-cmd.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/trace-cmd.h b/trace-cmd.h index 83e7a34..22b45cc 100644 --- a/trace-cmd.h +++ b/trace-cmd.h | |||
@@ -87,6 +87,15 @@ int tracecmd_init_data(struct tracecmd_input *handle); | |||
87 | struct record * | 87 | struct record * |
88 | tracecmd_peek_data(struct tracecmd_input *handle, int cpu); | 88 | tracecmd_peek_data(struct tracecmd_input *handle, int cpu); |
89 | 89 | ||
90 | static inline struct record * | ||
91 | tracecmd_peek_data_ref(struct tracecmd_input *handle, int cpu) | ||
92 | { | ||
93 | struct record *rec = tracecmd_peek_data(handle, cpu); | ||
94 | if (rec) | ||
95 | rec->ref_count++; | ||
96 | return rec; | ||
97 | } | ||
98 | |||
90 | struct record * | 99 | struct record * |
91 | tracecmd_read_data(struct tracecmd_input *handle, int cpu); | 100 | tracecmd_read_data(struct tracecmd_input *handle, int cpu); |
92 | 101 | ||