add patch fix-potential-use-after-free-after-remounting-with-noblock_validity
[ext4-patch-queue.git] / jbd2-add-missing-tracepoint-for-reserved-handle
blobee4ae9bdedb01fd96250b6673890a818607af916
1 jbd2: add missing tracepoint for reserved handle
3 From: Xiaoguang Wang <xiaoguang.wang@linux.alibaba.com>
5 This issue was found when I use ebpf to trace every jbd2
6 handle's running info in dioread_nolock case.
8 Signed-off-by: Xiaoguang Wang <xiaoguang.wang@linux.alibaba.com>
9 Signed-off-by: Theodore Ts'o <tytso@mit.edu>
10 ---
11  fs/jbd2/transaction.c | 3 +++
12  1 file changed, 3 insertions(+)
14 diff --git a/fs/jbd2/transaction.c b/fs/jbd2/transaction.c
15 index 990e7b5062e7..afc06daee5bb 100644
16 --- a/fs/jbd2/transaction.c
17 +++ b/fs/jbd2/transaction.c
18 @@ -569,6 +569,9 @@ int jbd2_journal_start_reserved(handle_t *handle, unsigned int type,
19         }
20         handle->h_type = type;
21         handle->h_line_no = line_no;
22 +       trace_jbd2_handle_start(journal->j_fs_dev->bd_dev,
23 +                               handle->h_transaction->t_tid, type,
24 +                               line_no, handle->h_buffer_credits);
25         return 0;
26  }
27  EXPORT_SYMBOL(jbd2_journal_start_reserved);