diff options
Diffstat (limited to 'include/trace/events/jbd2.h')
-rw-r--r-- | include/trace/events/jbd2.h | 91 |
1 files changed, 39 insertions, 52 deletions
diff --git a/include/trace/events/jbd2.h b/include/trace/events/jbd2.h index 3c60b75adb9e..bf16545cc977 100644 --- a/include/trace/events/jbd2.h +++ b/include/trace/events/jbd2.h | |||
@@ -30,7 +30,7 @@ TRACE_EVENT(jbd2_checkpoint, | |||
30 | jbd2_dev_to_name(__entry->dev), __entry->result) | 30 | jbd2_dev_to_name(__entry->dev), __entry->result) |
31 | ); | 31 | ); |
32 | 32 | ||
33 | TRACE_EVENT(jbd2_start_commit, | 33 | DECLARE_EVENT_CLASS(jbd2_commit, |
34 | 34 | ||
35 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), | 35 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), |
36 | 36 | ||
@@ -53,73 +53,32 @@ TRACE_EVENT(jbd2_start_commit, | |||
53 | __entry->sync_commit) | 53 | __entry->sync_commit) |
54 | ); | 54 | ); |
55 | 55 | ||
56 | TRACE_EVENT(jbd2_commit_locking, | 56 | DEFINE_EVENT(jbd2_commit, jbd2_start_commit, |
57 | 57 | ||
58 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), | 58 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), |
59 | 59 | ||
60 | TP_ARGS(journal, commit_transaction), | 60 | TP_ARGS(journal, commit_transaction) |
61 | |||
62 | TP_STRUCT__entry( | ||
63 | __field( dev_t, dev ) | ||
64 | __field( char, sync_commit ) | ||
65 | __field( int, transaction ) | ||
66 | ), | ||
67 | |||
68 | TP_fast_assign( | ||
69 | __entry->dev = journal->j_fs_dev->bd_dev; | ||
70 | __entry->sync_commit = commit_transaction->t_synchronous_commit; | ||
71 | __entry->transaction = commit_transaction->t_tid; | ||
72 | ), | ||
73 | |||
74 | TP_printk("dev %s transaction %d sync %d", | ||
75 | jbd2_dev_to_name(__entry->dev), __entry->transaction, | ||
76 | __entry->sync_commit) | ||
77 | ); | 61 | ); |
78 | 62 | ||
79 | TRACE_EVENT(jbd2_commit_flushing, | 63 | DEFINE_EVENT(jbd2_commit, jbd2_commit_locking, |
80 | 64 | ||
81 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), | 65 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), |
82 | 66 | ||
83 | TP_ARGS(journal, commit_transaction), | 67 | TP_ARGS(journal, commit_transaction) |
84 | |||
85 | TP_STRUCT__entry( | ||
86 | __field( dev_t, dev ) | ||
87 | __field( char, sync_commit ) | ||
88 | __field( int, transaction ) | ||
89 | ), | ||
90 | |||
91 | TP_fast_assign( | ||
92 | __entry->dev = journal->j_fs_dev->bd_dev; | ||
93 | __entry->sync_commit = commit_transaction->t_synchronous_commit; | ||
94 | __entry->transaction = commit_transaction->t_tid; | ||
95 | ), | ||
96 | |||
97 | TP_printk("dev %s transaction %d sync %d", | ||
98 | jbd2_dev_to_name(__entry->dev), __entry->transaction, | ||
99 | __entry->sync_commit) | ||
100 | ); | 68 | ); |
101 | 69 | ||
102 | TRACE_EVENT(jbd2_commit_logging, | 70 | DEFINE_EVENT(jbd2_commit, jbd2_commit_flushing, |
103 | 71 | ||
104 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), | 72 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), |
105 | 73 | ||
106 | TP_ARGS(journal, commit_transaction), | 74 | TP_ARGS(journal, commit_transaction) |
75 | ); | ||
107 | 76 | ||
108 | TP_STRUCT__entry( | 77 | DEFINE_EVENT(jbd2_commit, jbd2_commit_logging, |
109 | __field( dev_t, dev ) | ||
110 | __field( char, sync_commit ) | ||
111 | __field( int, transaction ) | ||
112 | ), | ||
113 | 78 | ||
114 | TP_fast_assign( | 79 | TP_PROTO(journal_t *journal, transaction_t *commit_transaction), |
115 | __entry->dev = journal->j_fs_dev->bd_dev; | ||
116 | __entry->sync_commit = commit_transaction->t_synchronous_commit; | ||
117 | __entry->transaction = commit_transaction->t_tid; | ||
118 | ), | ||
119 | 80 | ||
120 | TP_printk("dev %s transaction %d sync %d", | 81 | TP_ARGS(journal, commit_transaction) |
121 | jbd2_dev_to_name(__entry->dev), __entry->transaction, | ||
122 | __entry->sync_commit) | ||
123 | ); | 82 | ); |
124 | 83 | ||
125 | TRACE_EVENT(jbd2_end_commit, | 84 | TRACE_EVENT(jbd2_end_commit, |
@@ -240,6 +199,34 @@ TRACE_EVENT(jbd2_checkpoint_stats, | |||
240 | __entry->forced_to_close, __entry->written, __entry->dropped) | 199 | __entry->forced_to_close, __entry->written, __entry->dropped) |
241 | ); | 200 | ); |
242 | 201 | ||
202 | TRACE_EVENT(jbd2_cleanup_journal_tail, | ||
203 | |||
204 | TP_PROTO(journal_t *journal, tid_t first_tid, | ||
205 | unsigned long block_nr, unsigned long freed), | ||
206 | |||
207 | TP_ARGS(journal, first_tid, block_nr, freed), | ||
208 | |||
209 | TP_STRUCT__entry( | ||
210 | __field( dev_t, dev ) | ||
211 | __field( tid_t, tail_sequence ) | ||
212 | __field( tid_t, first_tid ) | ||
213 | __field(unsigned long, block_nr ) | ||
214 | __field(unsigned long, freed ) | ||
215 | ), | ||
216 | |||
217 | TP_fast_assign( | ||
218 | __entry->dev = journal->j_fs_dev->bd_dev; | ||
219 | __entry->tail_sequence = journal->j_tail_sequence; | ||
220 | __entry->first_tid = first_tid; | ||
221 | __entry->block_nr = block_nr; | ||
222 | __entry->freed = freed; | ||
223 | ), | ||
224 | |||
225 | TP_printk("dev %s from %u to %u offset %lu freed %lu", | ||
226 | jbd2_dev_to_name(__entry->dev), __entry->tail_sequence, | ||
227 | __entry->first_tid, __entry->block_nr, __entry->freed) | ||
228 | ); | ||
229 | |||
243 | #endif /* _TRACE_JBD2_H */ | 230 | #endif /* _TRACE_JBD2_H */ |
244 | 231 | ||
245 | /* This part must be outside protection */ | 232 | /* This part must be outside protection */ |