Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 185853
b: refs/heads/master
c: 71f2be2
h: refs/heads/master
i:
  185851: 198297d
v: v3
  • Loading branch information
Theodore Ts'o committed Dec 23, 2009
1 parent 0917fb4 commit 8ef033a
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1f2acb6017d8528135ec3b01ab7cd2be6ea0630b
refs/heads/master: 71f2be213a0009098819e5c04f75ff19f84f2122
1 change: 1 addition & 0 deletions trunk/fs/jbd2/checkpoint.c
Original file line number Diff line number Diff line change
Expand Up @@ -507,6 +507,7 @@ int jbd2_cleanup_journal_tail(journal_t *journal)
if (blocknr < journal->j_tail)
freed = freed + journal->j_last - journal->j_first;

trace_jbd2_cleanup_journal_tail(journal, first_tid, blocknr, freed);
jbd_debug(1,
"Cleaning journal tail from %d to %d (offset %lu), "
"freeing %lu\n",
Expand Down
28 changes: 28 additions & 0 deletions trunk/include/trace/events/jbd2.h
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,34 @@ TRACE_EVENT(jbd2_checkpoint_stats,
__entry->forced_to_close, __entry->written, __entry->dropped)
);

TRACE_EVENT(jbd2_cleanup_journal_tail,

TP_PROTO(journal_t *journal, tid_t first_tid,
unsigned long block_nr, unsigned long freed),

TP_ARGS(journal, first_tid, block_nr, freed),

TP_STRUCT__entry(
__field( dev_t, dev )
__field( tid_t, tail_sequence )
__field( tid_t, first_tid )
__field(unsigned long, block_nr )
__field(unsigned long, freed )
),

TP_fast_assign(
__entry->dev = journal->j_fs_dev->bd_dev;
__entry->tail_sequence = journal->j_tail_sequence;
__entry->first_tid = first_tid;
__entry->block_nr = block_nr;
__entry->freed = freed;
),

TP_printk("dev %s from %u to %u offset %lu freed %lu",
jbd2_dev_to_name(__entry->dev), __entry->tail_sequence,
__entry->first_tid, __entry->block_nr, __entry->freed)
);

#endif /* _TRACE_JBD2_H */

/* This part must be outside protection */
Expand Down

0 comments on commit 8ef033a

Please sign in to comment.