Commit | Line | Data |
---|---|---|
b7cdc182 | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
b87700e3 AG |
2 | #undef TRACE_SYSTEM |
3 | #define TRACE_SYSTEM btrfs | |
4 | ||
3bc29f0a MD |
5 | #if !defined(LTTNG_TRACE_BTRFS_H) || defined(TRACE_HEADER_MULTI_READ) |
6 | #define LTTNG_TRACE_BTRFS_H | |
b87700e3 | 7 | |
3b4aafcb | 8 | #include <lttng/tracepoint-event.h> |
b87700e3 | 9 | #include <linux/writeback.h> |
5f4c791e | 10 | #include <lttng/kernel-version.h> |
b87700e3 | 11 | |
4e4fb933 MJ |
12 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,2,0)) |
13 | #include <../fs/btrfs/accessors.h> | |
14 | #endif | |
15 | ||
f39b4a3c MJ |
16 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,3,0)) |
17 | #include <../fs/btrfs/extent-tree.h> | |
18 | #endif | |
19 | ||
b87700e3 AG |
20 | #ifndef _TRACE_BTRFS_DEF_ |
21 | #define _TRACE_BTRFS_DEF_ | |
22 | struct btrfs_root; | |
23 | struct btrfs_fs_info; | |
24 | struct btrfs_inode; | |
25 | struct extent_map; | |
26 | struct btrfs_ordered_extent; | |
27 | struct btrfs_delayed_ref_node; | |
28 | struct btrfs_delayed_tree_ref; | |
29 | struct btrfs_delayed_data_ref; | |
30 | struct btrfs_delayed_ref_head; | |
5f4c791e | 31 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
5809d816 | 32 | struct btrfs_block_group; |
3b67cf3e | 33 | #else |
b87700e3 | 34 | struct btrfs_block_group_cache; |
5809d816 | 35 | #endif |
b87700e3 | 36 | struct btrfs_free_cluster; |
b87700e3 AG |
37 | struct map_lookup; |
38 | struct extent_buffer; | |
b87700e3 AG |
39 | struct extent_state; |
40 | #endif | |
b87700e3 | 41 | |
b87700e3 AG |
42 | #define BTRFS_UUID_SIZE 16 |
43 | ||
5f4c791e | 44 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,0,0)) |
9d2f1147 MJ |
45 | #define lttng_fs_info_fsid fs_info->fs_devices->fsid |
46 | #else | |
47 | #define lttng_fs_info_fsid fs_info->fsid | |
48 | #endif | |
49 | ||
0fe69821 MJ |
50 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,17,0)) |
51 | LTTNG_TRACEPOINT_EVENT(btrfs_transaction_commit, | |
52 | ||
53 | TP_PROTO(const struct btrfs_fs_info *fs_info), | |
54 | ||
55 | TP_ARGS(fs_info), | |
56 | ||
57 | TP_FIELDS( | |
58 | ctf_integer(u64, generation, fs_info->generation) | |
59 | ctf_integer(u64, root_objectid, BTRFS_ROOT_TREE_OBJECTID) | |
60 | ) | |
61 | ) | |
62 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ | |
0badc02f MJ |
63 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
64 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
65 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 66 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
67 | LTTNG_TRACEPOINT_EVENT(btrfs_transaction_commit, |
68 | ||
69 | TP_PROTO(const struct btrfs_root *root), | |
70 | ||
71 | TP_ARGS(root), | |
72 | ||
73 | TP_FIELDS( | |
74 | ctf_integer(u64, generation, root->fs_info->generation) | |
75 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
76 | ) | |
77 | ) | |
0fe69821 MJ |
78 | #else |
79 | LTTNG_TRACEPOINT_EVENT(btrfs_transaction_commit, | |
80 | ||
81 | TP_PROTO(struct btrfs_root *root), | |
82 | ||
83 | TP_ARGS(root), | |
84 | ||
85 | TP_FIELDS( | |
86 | ctf_integer(u64, generation, root->fs_info->generation) | |
87 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
88 | ) | |
89 | ) | |
90 | #endif | |
1f1ec4ed | 91 | |
0fe69821 MJ |
92 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
93 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ | |
94 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
95 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
96 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
1f1ec4ed MJ |
97 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__inode, |
98 | ||
99 | TP_PROTO(const struct inode *inode), | |
100 | ||
101 | TP_ARGS(inode), | |
102 | ||
103 | TP_FIELDS( | |
104 | ctf_integer(ino_t, ino, inode->i_ino) | |
105 | ctf_integer(blkcnt_t, blocks, inode->i_blocks) | |
106 | ctf_integer(u64, disk_i_size, BTRFS_I(inode)->disk_i_size) | |
107 | ctf_integer(u64, generation, BTRFS_I(inode)->generation) | |
108 | ctf_integer(u64, last_trans, BTRFS_I(inode)->last_trans) | |
109 | ctf_integer(u64, logged_trans, BTRFS_I(inode)->logged_trans) | |
110 | ctf_integer(u64, root_objectid, | |
111 | BTRFS_I(inode)->root->root_key.objectid) | |
112 | ) | |
113 | ) | |
114 | ||
115 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_new, | |
116 | ||
117 | TP_PROTO(const struct inode *inode), | |
118 | ||
119 | TP_ARGS(inode) | |
120 | ) | |
121 | ||
122 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_request, | |
123 | ||
124 | TP_PROTO(const struct inode *inode), | |
125 | ||
126 | TP_ARGS(inode) | |
127 | ) | |
128 | ||
129 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_evict, | |
130 | ||
131 | TP_PROTO(const struct inode *inode), | |
132 | ||
133 | TP_ARGS(inode) | |
134 | ) | |
135 | #else | |
3bc29f0a | 136 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__inode, |
b87700e3 AG |
137 | |
138 | TP_PROTO(struct inode *inode), | |
139 | ||
140 | TP_ARGS(inode), | |
141 | ||
f127e61e MD |
142 | TP_FIELDS( |
143 | ctf_integer(ino_t, ino, inode->i_ino) | |
144 | ctf_integer(blkcnt_t, blocks, inode->i_blocks) | |
145 | ctf_integer(u64, disk_i_size, BTRFS_I(inode)->disk_i_size) | |
146 | ctf_integer(u64, generation, BTRFS_I(inode)->generation) | |
147 | ctf_integer(u64, last_trans, BTRFS_I(inode)->last_trans) | |
148 | ctf_integer(u64, logged_trans, BTRFS_I(inode)->logged_trans) | |
149 | ctf_integer(u64, root_objectid, | |
b87700e3 | 150 | BTRFS_I(inode)->root->root_key.objectid) |
f127e61e | 151 | ) |
b87700e3 AG |
152 | ) |
153 | ||
3bc29f0a | 154 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_new, |
b87700e3 AG |
155 | |
156 | TP_PROTO(struct inode *inode), | |
157 | ||
158 | TP_ARGS(inode) | |
159 | ) | |
160 | ||
3bc29f0a | 161 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_request, |
b87700e3 AG |
162 | |
163 | TP_PROTO(struct inode *inode), | |
164 | ||
165 | TP_ARGS(inode) | |
166 | ) | |
167 | ||
3bc29f0a | 168 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__inode, btrfs_inode_evict, |
b87700e3 AG |
169 | |
170 | TP_PROTO(struct inode *inode), | |
171 | ||
172 | TP_ARGS(inode) | |
173 | ) | |
1f1ec4ed MJ |
174 | #endif |
175 | ||
0c9bc964 KS |
176 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,8,0)) |
177 | ||
178 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
179 | ||
180 | TP_PROTO(const struct btrfs_root *root, const struct btrfs_inode *inode, | |
181 | const struct extent_map *map), | |
182 | ||
183 | TP_ARGS(root, inode, map), | |
184 | ||
185 | TP_FIELDS( | |
186 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
187 | ctf_integer(u64, ino, btrfs_ino(inode)) | |
188 | ctf_integer(u64, start, map->start) | |
189 | ctf_integer(u64, len, map->len) | |
190 | ctf_integer(u64, orig_start, map->orig_start) | |
191 | ctf_integer(u64, block_start, map->block_start) | |
192 | ctf_integer(u64, block_len, map->block_len) | |
193 | ctf_integer(unsigned int, flags, map->flags) | |
194 | ctf_integer(int, refs, refcount_read(&map->refs)) | |
195 | ctf_integer(unsigned int, compress_type, extent_map_compression(map)) | |
196 | ) | |
197 | ) | |
198 | ||
199 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) | |
1f1ec4ed MJ |
200 | |
201 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
202 | ||
203 | TP_PROTO(const struct btrfs_root *root, const struct btrfs_inode *inode, | |
204 | const struct extent_map *map), | |
205 | ||
206 | TP_ARGS(root, inode, map), | |
207 | ||
208 | TP_FIELDS( | |
209 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
210 | ctf_integer(u64, ino, btrfs_ino(inode)) | |
211 | ctf_integer(u64, start, map->start) | |
212 | ctf_integer(u64, len, map->len) | |
213 | ctf_integer(u64, orig_start, map->orig_start) | |
214 | ctf_integer(u64, block_start, map->block_start) | |
215 | ctf_integer(u64, block_len, map->block_len) | |
216 | ctf_integer(unsigned long, flags, map->flags) | |
217 | ctf_integer(int, refs, refcount_read(&map->refs)) | |
218 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
219 | ) | |
220 | ) | |
b87700e3 | 221 | |
5f4c791e | 222 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,12,0)) |
5807b1af MJ |
223 | |
224 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
225 | ||
226 | TP_PROTO(struct btrfs_root *root, struct btrfs_inode *inode, | |
227 | struct extent_map *map), | |
228 | ||
229 | TP_ARGS(root, inode, map), | |
230 | ||
231 | TP_FIELDS( | |
232 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
233 | ctf_integer(u64, ino, btrfs_ino(inode)) | |
234 | ctf_integer(u64, start, map->start) | |
235 | ctf_integer(u64, len, map->len) | |
236 | ctf_integer(u64, orig_start, map->orig_start) | |
237 | ctf_integer(u64, block_start, map->block_start) | |
238 | ctf_integer(u64, block_len, map->block_len) | |
239 | ctf_integer(unsigned long, flags, map->flags) | |
240 | ctf_integer(int, refs, refcount_read(&map->refs)) | |
241 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
242 | ) | |
243 | ) | |
244 | ||
5f4c791e | 245 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,11,0)) |
e52717ea FD |
246 | |
247 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
248 | ||
249 | TP_PROTO(struct btrfs_root *root, struct btrfs_inode *inode, | |
250 | struct extent_map *map), | |
251 | ||
252 | TP_ARGS(root, inode, map), | |
253 | ||
254 | TP_FIELDS( | |
255 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
256 | ctf_integer(u64, ino, btrfs_ino(inode)) | |
257 | ctf_integer(u64, start, map->start) | |
258 | ctf_integer(u64, len, map->len) | |
259 | ctf_integer(u64, orig_start, map->orig_start) | |
260 | ctf_integer(u64, block_start, map->block_start) | |
261 | ctf_integer(u64, block_len, map->block_len) | |
262 | ctf_integer(unsigned long, flags, map->flags) | |
263 | ctf_integer(int, refs, atomic_read(&map->refs)) | |
264 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
265 | ) | |
266 | ) | |
267 | ||
5f4c791e | 268 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) |
f1a87e24 | 269 | |
3bc29f0a | 270 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, |
b87700e3 | 271 | |
f3166f27 MD |
272 | TP_PROTO(struct btrfs_root *root, struct inode *inode, |
273 | struct extent_map *map), | |
b87700e3 | 274 | |
f3166f27 | 275 | TP_ARGS(root, inode, map), |
b87700e3 | 276 | |
f127e61e MD |
277 | TP_FIELDS( |
278 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
f3166f27 | 279 | ctf_integer(u64, ino, btrfs_ino(inode)) |
f127e61e MD |
280 | ctf_integer(u64, start, map->start) |
281 | ctf_integer(u64, len, map->len) | |
282 | ctf_integer(u64, orig_start, map->orig_start) | |
283 | ctf_integer(u64, block_start, map->block_start) | |
284 | ctf_integer(u64, block_len, map->block_len) | |
285 | ctf_integer(unsigned long, flags, map->flags) | |
286 | ctf_integer(int, refs, atomic_read(&map->refs)) | |
287 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
288 | ) | |
b87700e3 AG |
289 | ) |
290 | ||
0badc02f MJ |
291 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
292 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
293 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
294 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
7ca7cd6e MJ |
295 | |
296 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
297 | ||
298 | TP_PROTO(const struct btrfs_root *root, const struct extent_map *map), | |
299 | ||
300 | TP_ARGS(root, map), | |
301 | ||
302 | TP_FIELDS( | |
303 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
304 | ctf_integer(u64, start, map->start) | |
305 | ctf_integer(u64, len, map->len) | |
306 | ctf_integer(u64, orig_start, map->orig_start) | |
307 | ctf_integer(u64, block_start, map->block_start) | |
308 | ctf_integer(u64, block_len, map->block_len) | |
309 | ctf_integer(unsigned long, flags, map->flags) | |
310 | ctf_integer(int, refs, atomic_read(&map->refs)) | |
311 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
312 | ) | |
313 | ) | |
314 | ||
5f4c791e | 315 | #else /* #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
f1a87e24 MD |
316 | |
317 | LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, | |
318 | ||
319 | TP_PROTO(struct btrfs_root *root, struct extent_map *map), | |
320 | ||
321 | TP_ARGS(root, map), | |
322 | ||
323 | TP_FIELDS( | |
324 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
325 | ctf_integer(u64, start, map->start) | |
326 | ctf_integer(u64, len, map->len) | |
327 | ctf_integer(u64, orig_start, map->orig_start) | |
328 | ctf_integer(u64, block_start, map->block_start) | |
329 | ctf_integer(u64, block_len, map->block_len) | |
330 | ctf_integer(unsigned long, flags, map->flags) | |
331 | ctf_integer(int, refs, atomic_read(&map->refs)) | |
332 | ctf_integer(unsigned int, compress_type, map->compress_type) | |
333 | ) | |
334 | ) | |
335 | ||
5f4c791e | 336 | #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
f1a87e24 | 337 | |
5f4c791e | 338 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
ae5af8ea MJ |
339 | LTTNG_TRACEPOINT_EVENT(btrfs_handle_em_exist, |
340 | ||
341 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
342 | const struct extent_map *existing, const struct extent_map *map, | |
343 | u64 start, u64 len), | |
344 | ||
345 | TP_ARGS(fs_info, existing, map, start, len), | |
346 | ||
347 | TP_FIELDS( | |
348 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
349 | ctf_integer(u64, e_start, existing->start) | |
350 | ctf_integer(u64, e_len, existing->len) | |
351 | ctf_integer(u64, map_start, map->start) | |
352 | ctf_integer(u64, map_len, map->len) | |
353 | ctf_integer(u64, start, start) | |
354 | ctf_integer(u64, len, len) | |
355 | ) | |
356 | ) | |
5f4c791e | 357 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,18,0)) |
354b9790 MJ |
358 | LTTNG_TRACEPOINT_EVENT(btrfs_handle_em_exist, |
359 | ||
360 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
361 | const struct extent_map *existing, const struct extent_map *map, | |
362 | u64 start, u64 len), | |
363 | ||
364 | TP_ARGS(fs_info, existing, map, start, len), | |
365 | ||
366 | TP_FIELDS( | |
9d2f1147 | 367 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
354b9790 MJ |
368 | ctf_integer(u64, e_start, existing->start) |
369 | ctf_integer(u64, e_len, existing->len) | |
370 | ctf_integer(u64, map_start, map->start) | |
371 | ctf_integer(u64, map_len, map->len) | |
372 | ctf_integer(u64, start, start) | |
373 | ctf_integer(u64, len, len) | |
374 | ) | |
375 | ) | |
5f4c791e | 376 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,17,0)) |
22df20ca MJ |
377 | LTTNG_TRACEPOINT_EVENT(btrfs_handle_em_exist, |
378 | ||
379 | TP_PROTO(const struct extent_map *existing, const struct extent_map *map, u64 start, u64 len), | |
380 | ||
381 | TP_ARGS(existing, map, start, len), | |
382 | ||
383 | TP_FIELDS( | |
384 | ctf_integer(u64, e_start, existing->start) | |
385 | ctf_integer(u64, e_len, existing->len) | |
386 | ctf_integer(u64, map_start, map->start) | |
387 | ctf_integer(u64, map_len, map->len) | |
388 | ctf_integer(u64, start, start) | |
389 | ctf_integer(u64, len, len) | |
390 | ) | |
391 | ) | |
392 | #endif | |
393 | ||
5f4c791e | 394 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,10,0)) |
7dc44138 MJ |
395 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
396 | ||
397 | TP_PROTO(const struct btrfs_inode *inode, | |
398 | const struct btrfs_ordered_extent *ordered), | |
399 | ||
400 | TP_ARGS(inode, ordered), | |
401 | ||
402 | TP_FIELDS( | |
403 | ctf_array(u8, fsid, inode->root->lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
404 | ctf_integer(ino_t, ino, btrfs_ino(inode)) | |
405 | ctf_integer(u64, file_offset, ordered->file_offset) | |
406 | ctf_integer(u64, start, ordered->disk_bytenr) | |
407 | ctf_integer(u64, len, ordered->num_bytes) | |
408 | ctf_integer(u64, disk_len, ordered->disk_num_bytes) | |
409 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
410 | ctf_integer(unsigned long, flags, ordered->flags) | |
411 | ctf_integer(int, compress_type, ordered->compress_type) | |
412 | ctf_integer(int, refs, refcount_read(&ordered->refs)) | |
413 | ctf_integer(u64, root_objectid, inode->root->root_key.objectid) | |
414 | ) | |
415 | ) | |
5f4c791e | 416 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0)) |
f7afb954 MJ |
417 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
418 | ||
419 | TP_PROTO(const struct inode *inode, | |
420 | const struct btrfs_ordered_extent *ordered), | |
421 | ||
422 | TP_ARGS(inode, ordered), | |
423 | ||
424 | TP_FIELDS( | |
425 | ctf_integer(ino_t, ino, inode->i_ino) | |
426 | ctf_integer(u64, file_offset, ordered->file_offset) | |
427 | ctf_integer(u64, start, ordered->disk_bytenr) | |
428 | ctf_integer(u64, len, ordered->num_bytes) | |
429 | ctf_integer(u64, disk_len, ordered->disk_num_bytes) | |
430 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
431 | ctf_integer(unsigned long, flags, ordered->flags) | |
432 | ctf_integer(int, compress_type, ordered->compress_type) | |
433 | ctf_integer(int, refs, refcount_read(&ordered->refs)) | |
434 | ctf_integer(u64, root_objectid, | |
435 | BTRFS_I(inode)->root->root_key.objectid) | |
436 | ) | |
437 | ) | |
5f4c791e | 438 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) |
1f1ec4ed MJ |
439 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
440 | ||
441 | TP_PROTO(const struct inode *inode, | |
442 | const struct btrfs_ordered_extent *ordered), | |
443 | ||
444 | TP_ARGS(inode, ordered), | |
445 | ||
446 | TP_FIELDS( | |
447 | ctf_integer(ino_t, ino, inode->i_ino) | |
448 | ctf_integer(u64, file_offset, ordered->file_offset) | |
449 | ctf_integer(u64, start, ordered->start) | |
450 | ctf_integer(u64, len, ordered->len) | |
451 | ctf_integer(u64, disk_len, ordered->disk_len) | |
452 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
453 | ctf_integer(unsigned long, flags, ordered->flags) | |
454 | ctf_integer(int, compress_type, ordered->compress_type) | |
455 | ctf_integer(int, refs, refcount_read(&ordered->refs)) | |
456 | ctf_integer(u64, root_objectid, | |
457 | BTRFS_I(inode)->root->root_key.objectid) | |
458 | ) | |
459 | ) | |
5f4c791e | 460 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,12,0)) |
5807b1af MJ |
461 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
462 | ||
463 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), | |
464 | ||
465 | TP_ARGS(inode, ordered), | |
466 | ||
467 | TP_FIELDS( | |
468 | ctf_integer(ino_t, ino, inode->i_ino) | |
469 | ctf_integer(u64, file_offset, ordered->file_offset) | |
470 | ctf_integer(u64, start, ordered->start) | |
471 | ctf_integer(u64, len, ordered->len) | |
472 | ctf_integer(u64, disk_len, ordered->disk_len) | |
473 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
474 | ctf_integer(unsigned long, flags, ordered->flags) | |
475 | ctf_integer(int, compress_type, ordered->compress_type) | |
476 | ctf_integer(int, refs, refcount_read(&ordered->refs)) | |
477 | ctf_integer(u64, root_objectid, | |
478 | BTRFS_I(inode)->root->root_key.objectid) | |
479 | ) | |
480 | ) | |
0badc02f MJ |
481 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
482 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
483 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
484 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
7ca7cd6e MJ |
485 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
486 | ||
487 | TP_PROTO(const struct inode *inode, const struct btrfs_ordered_extent *ordered), | |
488 | ||
489 | TP_ARGS(inode, ordered), | |
490 | ||
491 | TP_FIELDS( | |
492 | ctf_integer(ino_t, ino, inode->i_ino) | |
493 | ctf_integer(u64, file_offset, ordered->file_offset) | |
494 | ctf_integer(u64, start, ordered->start) | |
495 | ctf_integer(u64, len, ordered->len) | |
496 | ctf_integer(u64, disk_len, ordered->disk_len) | |
497 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
498 | ctf_integer(unsigned long, flags, ordered->flags) | |
499 | ctf_integer(int, compress_type, ordered->compress_type) | |
500 | ctf_integer(int, refs, atomic_read(&ordered->refs)) | |
501 | ctf_integer(u64, root_objectid, | |
502 | BTRFS_I(inode)->root->root_key.objectid) | |
503 | ) | |
504 | ) | |
5807b1af | 505 | #else |
3bc29f0a | 506 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, |
b87700e3 AG |
507 | |
508 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), | |
509 | ||
510 | TP_ARGS(inode, ordered), | |
511 | ||
f127e61e MD |
512 | TP_FIELDS( |
513 | ctf_integer(ino_t, ino, inode->i_ino) | |
514 | ctf_integer(u64, file_offset, ordered->file_offset) | |
515 | ctf_integer(u64, start, ordered->start) | |
516 | ctf_integer(u64, len, ordered->len) | |
517 | ctf_integer(u64, disk_len, ordered->disk_len) | |
518 | ctf_integer(u64, bytes_left, ordered->bytes_left) | |
519 | ctf_integer(unsigned long, flags, ordered->flags) | |
520 | ctf_integer(int, compress_type, ordered->compress_type) | |
521 | ctf_integer(int, refs, atomic_read(&ordered->refs)) | |
522 | ctf_integer(u64, root_objectid, | |
b87700e3 | 523 | BTRFS_I(inode)->root->root_key.objectid) |
f127e61e | 524 | ) |
b87700e3 | 525 | ) |
5807b1af | 526 | #endif |
b87700e3 | 527 | |
5f4c791e | 528 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,10,0)) |
7dc44138 MJ |
529 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_add, |
530 | ||
531 | TP_PROTO(const struct btrfs_inode *inode, | |
532 | const struct btrfs_ordered_extent *ordered), | |
533 | ||
534 | TP_ARGS(inode, ordered) | |
535 | ) | |
536 | ||
537 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_remove, | |
538 | ||
539 | TP_PROTO(const struct btrfs_inode *inode, | |
540 | const struct btrfs_ordered_extent *ordered), | |
541 | ||
542 | TP_ARGS(inode, ordered) | |
543 | ) | |
544 | ||
545 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_start, | |
546 | ||
547 | TP_PROTO(const struct btrfs_inode *inode, | |
548 | const struct btrfs_ordered_extent *ordered), | |
549 | ||
550 | TP_ARGS(inode, ordered) | |
551 | ) | |
552 | ||
553 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_put, | |
554 | ||
555 | TP_PROTO(const struct btrfs_inode *inode, | |
556 | const struct btrfs_ordered_extent *ordered), | |
557 | ||
558 | TP_ARGS(inode, ordered) | |
559 | ) | |
5f4c791e | 560 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
561 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
562 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
563 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 564 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
565 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_add, |
566 | ||
567 | TP_PROTO(const struct inode *inode, | |
568 | const struct btrfs_ordered_extent *ordered), | |
569 | ||
570 | TP_ARGS(inode, ordered) | |
571 | ) | |
572 | ||
573 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_remove, | |
574 | ||
575 | TP_PROTO(const struct inode *inode, | |
576 | const struct btrfs_ordered_extent *ordered), | |
577 | ||
578 | TP_ARGS(inode, ordered) | |
579 | ) | |
580 | ||
581 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_start, | |
582 | ||
583 | TP_PROTO(const struct inode *inode, | |
584 | const struct btrfs_ordered_extent *ordered), | |
585 | ||
586 | TP_ARGS(inode, ordered) | |
587 | ) | |
588 | ||
589 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_put, | |
590 | ||
591 | TP_PROTO(const struct inode *inode, | |
592 | const struct btrfs_ordered_extent *ordered), | |
593 | ||
594 | TP_ARGS(inode, ordered) | |
595 | ) | |
7dc44138 MJ |
596 | #else |
597 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_add, | |
598 | ||
599 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), | |
600 | ||
601 | TP_ARGS(inode, ordered) | |
602 | ) | |
603 | ||
604 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_remove, | |
1f1ec4ed | 605 | |
7dc44138 MJ |
606 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), |
607 | ||
608 | TP_ARGS(inode, ordered) | |
609 | ) | |
610 | ||
611 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_start, | |
612 | ||
613 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), | |
614 | ||
615 | TP_ARGS(inode, ordered) | |
616 | ) | |
617 | ||
618 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_put, | |
619 | ||
620 | TP_PROTO(struct inode *inode, struct btrfs_ordered_extent *ordered), | |
621 | ||
622 | TP_ARGS(inode, ordered) | |
623 | ) | |
624 | #endif | |
625 | ||
18a23dc8 MJ |
626 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,0,0)) |
627 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_lookup, | |
628 | ||
629 | TP_PROTO(const struct btrfs_inode *inode, | |
630 | const struct btrfs_ordered_extent *ordered), | |
631 | ||
632 | TP_ARGS(inode, ordered) | |
633 | ) | |
634 | ||
635 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_lookup_range, | |
636 | ||
637 | TP_PROTO(const struct btrfs_inode *inode, | |
638 | const struct btrfs_ordered_extent *ordered), | |
639 | ||
640 | TP_ARGS(inode, ordered) | |
641 | ) | |
642 | ||
643 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_lookup_first_range, | |
644 | ||
645 | TP_PROTO(const struct btrfs_inode *inode, | |
646 | const struct btrfs_ordered_extent *ordered), | |
647 | ||
648 | TP_ARGS(inode, ordered) | |
649 | ) | |
650 | ||
651 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_lookup_for_logging, | |
652 | ||
653 | TP_PROTO(const struct btrfs_inode *inode, | |
654 | const struct btrfs_ordered_extent *ordered), | |
655 | ||
656 | TP_ARGS(inode, ordered) | |
657 | ) | |
658 | ||
659 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_lookup_first, | |
660 | ||
661 | TP_PROTO(const struct btrfs_inode *inode, | |
662 | const struct btrfs_ordered_extent *ordered), | |
663 | ||
664 | TP_ARGS(inode, ordered) | |
665 | ) | |
666 | ||
667 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_split, | |
668 | ||
669 | TP_PROTO(const struct btrfs_inode *inode, | |
670 | const struct btrfs_ordered_extent *ordered), | |
671 | ||
672 | TP_ARGS(inode, ordered) | |
673 | ) | |
674 | ||
675 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_dec_test_pending, | |
676 | ||
677 | TP_PROTO(const struct btrfs_inode *inode, | |
678 | const struct btrfs_ordered_extent *ordered), | |
679 | ||
680 | TP_ARGS(inode, ordered) | |
681 | ) | |
682 | ||
683 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_mark_finished, | |
684 | ||
685 | TP_PROTO(const struct btrfs_inode *inode, | |
686 | const struct btrfs_ordered_extent *ordered), | |
687 | ||
688 | TP_ARGS(inode, ordered) | |
689 | ) | |
690 | #endif | |
691 | ||
e9a88656 MJ |
692 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,14,0)) |
693 | LTTNG_TRACEPOINT_EVENT(btrfs_writepage_end_io_hook, | |
694 | ||
695 | TP_PROTO(const struct btrfs_inode *inode, u64 start, u64 end, int uptodate), | |
696 | ||
697 | TP_ARGS(inode, start, end, uptodate), | |
698 | ||
699 | TP_FIELDS( | |
700 | ctf_integer(u64, ino, btrfs_ino(inode)) | |
701 | ctf_integer(u64, start, start) | |
702 | ctf_integer(u64, end, end) | |
703 | ctf_integer(int, uptodate, uptodate) | |
704 | ctf_integer(u64, root_objectid, inode->root->root_key.objectid) | |
705 | ) | |
706 | ) | |
707 | ||
708 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ | |
709 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ | |
710 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
711 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
712 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
713 | ||
714 | LTTNG_TRACEPOINT_EVENT(btrfs_writepage_end_io_hook, | |
715 | ||
716 | TP_PROTO(const struct page *page, u64 start, u64 end, int uptodate), | |
717 | ||
718 | TP_ARGS(page, start, end, uptodate), | |
719 | ||
720 | TP_FIELDS( | |
721 | ctf_integer(ino_t, ino, page->mapping->host->i_ino) | |
722 | ctf_integer(pgoff_t, index, page->index) | |
723 | ctf_integer(u64, start, start) | |
724 | ctf_integer(u64, end, end) | |
725 | ctf_integer(int, uptodate, uptodate) | |
726 | ctf_integer(u64, root_objectid, | |
727 | BTRFS_I(page->mapping->host)->root->root_key.objectid) | |
728 | ) | |
729 | ) | |
730 | ||
731 | #else | |
732 | ||
733 | LTTNG_TRACEPOINT_EVENT(btrfs_writepage_end_io_hook, | |
734 | ||
735 | TP_PROTO(struct page *page, u64 start, u64 end, int uptodate), | |
736 | ||
737 | TP_ARGS(page, start, end, uptodate), | |
738 | ||
739 | TP_FIELDS( | |
740 | ctf_integer(ino_t, ino, page->mapping->host->i_ino) | |
741 | ctf_integer(pgoff_t, index, page->index) | |
742 | ctf_integer(u64, start, start) | |
743 | ctf_integer(u64, end, end) | |
744 | ctf_integer(int, uptodate, uptodate) | |
745 | ctf_integer(u64, root_objectid, | |
746 | BTRFS_I(page->mapping->host)->root->root_key.objectid) | |
747 | ) | |
748 | ) | |
749 | #endif | |
750 | ||
5f4c791e | 751 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
7dc44138 MJ |
752 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
753 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
754 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
755 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
1f1ec4ed MJ |
756 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__writepage, |
757 | ||
758 | TP_PROTO(const struct page *page, const struct inode *inode, | |
759 | const struct writeback_control *wbc), | |
760 | ||
761 | TP_ARGS(page, inode, wbc), | |
762 | ||
763 | TP_FIELDS( | |
764 | ctf_integer(ino_t, ino, inode->i_ino) | |
765 | ctf_integer(pgoff_t, index, page->index) | |
766 | ctf_integer(long, nr_to_write, wbc->nr_to_write) | |
767 | ctf_integer(long, pages_skipped, wbc->pages_skipped) | |
768 | ctf_integer(loff_t, range_start, wbc->range_start) | |
769 | ctf_integer(loff_t, range_end, wbc->range_end) | |
770 | ctf_integer(char, for_kupdate, wbc->for_kupdate) | |
771 | ctf_integer(char, for_reclaim, wbc->for_reclaim) | |
772 | ctf_integer(char, range_cyclic, wbc->range_cyclic) | |
773 | ctf_integer(pgoff_t, writeback_index, | |
774 | inode->i_mapping->writeback_index) | |
775 | ctf_integer(u64, root_objectid, | |
776 | BTRFS_I(inode)->root->root_key.objectid) | |
777 | ) | |
778 | ) | |
779 | ||
780 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs__writepage, | |
781 | ||
782 | __extent_writepage, | |
783 | ||
784 | btrfs__extent_writepage, | |
785 | ||
786 | TP_PROTO(const struct page *page, const struct inode *inode, | |
787 | const struct writeback_control *wbc), | |
788 | ||
789 | TP_ARGS(page, inode, wbc) | |
790 | ) | |
791 | ||
1f1ec4ed MJ |
792 | LTTNG_TRACEPOINT_EVENT(btrfs_sync_file, |
793 | ||
794 | TP_PROTO(const struct file *file, int datasync), | |
795 | ||
796 | TP_ARGS(file, datasync), | |
797 | ||
798 | TP_FIELDS( | |
799 | ctf_integer(ino_t, ino, file->f_path.dentry->d_inode->i_ino) | |
800 | ctf_integer(ino_t, parent, file->f_path.dentry->d_parent->d_inode->i_ino) | |
801 | ctf_integer(int, datasync, datasync) | |
802 | ctf_integer(u64, root_objectid, | |
803 | BTRFS_I(file->f_path.dentry->d_inode)->root->root_key.objectid) | |
804 | ) | |
805 | ) | |
806 | #else | |
3bc29f0a | 807 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__writepage, |
b87700e3 AG |
808 | |
809 | TP_PROTO(struct page *page, struct inode *inode, | |
810 | struct writeback_control *wbc), | |
811 | ||
812 | TP_ARGS(page, inode, wbc), | |
813 | ||
f127e61e MD |
814 | TP_FIELDS( |
815 | ctf_integer(ino_t, ino, inode->i_ino) | |
816 | ctf_integer(pgoff_t, index, page->index) | |
817 | ctf_integer(long, nr_to_write, wbc->nr_to_write) | |
818 | ctf_integer(long, pages_skipped, wbc->pages_skipped) | |
819 | ctf_integer(loff_t, range_start, wbc->range_start) | |
820 | ctf_integer(loff_t, range_end, wbc->range_end) | |
f127e61e MD |
821 | ctf_integer(char, for_kupdate, wbc->for_kupdate) |
822 | ctf_integer(char, for_reclaim, wbc->for_reclaim) | |
823 | ctf_integer(char, range_cyclic, wbc->range_cyclic) | |
824 | ctf_integer(pgoff_t, writeback_index, | |
825 | inode->i_mapping->writeback_index) | |
826 | ctf_integer(u64, root_objectid, | |
827 | BTRFS_I(inode)->root->root_key.objectid) | |
828 | ) | |
b87700e3 AG |
829 | ) |
830 | ||
9bbf98da MD |
831 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs__writepage, |
832 | ||
833 | __extent_writepage, | |
834 | ||
835 | btrfs__extent_writepage, | |
b87700e3 AG |
836 | |
837 | TP_PROTO(struct page *page, struct inode *inode, | |
838 | struct writeback_control *wbc), | |
839 | ||
840 | TP_ARGS(page, inode, wbc) | |
841 | ) | |
842 | ||
3bc29f0a | 843 | LTTNG_TRACEPOINT_EVENT(btrfs_sync_file, |
b87700e3 AG |
844 | |
845 | TP_PROTO(struct file *file, int datasync), | |
846 | ||
847 | TP_ARGS(file, datasync), | |
848 | ||
f127e61e MD |
849 | TP_FIELDS( |
850 | ctf_integer(ino_t, ino, file->f_path.dentry->d_inode->i_ino) | |
851 | ctf_integer(ino_t, parent, file->f_path.dentry->d_parent->d_inode->i_ino) | |
852 | ctf_integer(int, datasync, datasync) | |
853 | ctf_integer(u64, root_objectid, | |
b87700e3 | 854 | BTRFS_I(file->f_path.dentry->d_inode)->root->root_key.objectid) |
f127e61e | 855 | ) |
b87700e3 | 856 | ) |
1f1ec4ed | 857 | #endif |
b87700e3 | 858 | |
5f4c791e | 859 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
860 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
861 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
862 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
863 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ | |
864 | LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ | |
865 | LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ | |
866 | LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) | |
1f1ec4ed MJ |
867 | LTTNG_TRACEPOINT_EVENT(btrfs_sync_fs, |
868 | ||
869 | TP_PROTO(const struct btrfs_fs_info *fs_info, int wait), | |
870 | ||
871 | TP_ARGS(fs_info, wait), | |
872 | ||
873 | TP_FIELDS( | |
874 | ctf_integer(int, wait, wait) | |
875 | ) | |
876 | ) | |
5f4c791e | 877 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,8,0)) |
fcd0a11c MD |
878 | LTTNG_TRACEPOINT_EVENT(btrfs_sync_fs, |
879 | ||
880 | TP_PROTO(struct btrfs_fs_info *fs_info, int wait), | |
881 | ||
882 | TP_ARGS(fs_info, wait), | |
883 | ||
884 | TP_FIELDS( | |
885 | ctf_integer(int, wait, wait) | |
886 | ) | |
887 | ) | |
888 | #else | |
3bc29f0a | 889 | LTTNG_TRACEPOINT_EVENT(btrfs_sync_fs, |
b87700e3 AG |
890 | |
891 | TP_PROTO(int wait), | |
892 | ||
893 | TP_ARGS(wait), | |
894 | ||
f127e61e MD |
895 | TP_FIELDS( |
896 | ctf_integer(int, wait, wait) | |
897 | ) | |
b87700e3 | 898 | ) |
fcd0a11c MD |
899 | #endif |
900 | ||
5f4c791e | 901 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
5809d816 MJ |
902 | LTTNG_TRACEPOINT_EVENT(btrfs_add_block_group, |
903 | ||
904 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
905 | const struct btrfs_block_group *block_group, int create), | |
906 | ||
907 | TP_ARGS(fs_info, block_group, create), | |
908 | ||
909 | TP_FIELDS( | |
910 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
911 | ctf_integer(u64, offset, block_group->start) | |
912 | ctf_integer(u64, size, block_group->length) | |
913 | ctf_integer(u64, flags, block_group->flags) | |
914 | ctf_integer(u64, bytes_used, block_group->used) | |
915 | ctf_integer(u64, bytes_super, block_group->bytes_super) | |
916 | ctf_integer(int, create, create) | |
917 | ) | |
918 | ) | |
5f4c791e | 919 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
920 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
921 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
922 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 923 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
924 | LTTNG_TRACEPOINT_EVENT(btrfs_add_block_group, |
925 | ||
926 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
927 | const struct btrfs_block_group_cache *block_group, int create), | |
928 | ||
929 | TP_ARGS(fs_info, block_group, create), | |
930 | ||
931 | TP_FIELDS( | |
9d2f1147 | 932 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
1f1ec4ed MJ |
933 | ctf_integer(u64, offset, block_group->key.objectid) |
934 | ctf_integer(u64, size, block_group->key.offset) | |
935 | ctf_integer(u64, flags, block_group->flags) | |
936 | ctf_integer(u64, bytes_used, btrfs_block_group_used(&block_group->item)) | |
937 | ctf_integer(u64, bytes_super, block_group->bytes_super) | |
938 | ctf_integer(int, create, create) | |
939 | ) | |
940 | ) | |
941 | #else | |
fcd0a11c | 942 | LTTNG_TRACEPOINT_EVENT(btrfs_add_block_group, |
b87700e3 | 943 | |
fcd0a11c MD |
944 | TP_PROTO(struct btrfs_fs_info *fs_info, |
945 | struct btrfs_block_group_cache *block_group, int create), | |
946 | ||
947 | TP_ARGS(fs_info, block_group, create), | |
948 | ||
949 | TP_FIELDS( | |
9d2f1147 | 950 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
fcd0a11c MD |
951 | ctf_integer(u64, offset, block_group->key.objectid) |
952 | ctf_integer(u64, size, block_group->key.offset) | |
953 | ctf_integer(u64, flags, block_group->flags) | |
954 | ctf_integer(u64, bytes_used, btrfs_block_group_used(&block_group->item)) | |
955 | ctf_integer(u64, bytes_super, block_group->bytes_super) | |
956 | ctf_integer(int, create, create) | |
957 | ) | |
958 | ) | |
1f1ec4ed | 959 | #endif |
fcd0a11c | 960 | |
5f4c791e | 961 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
962 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
963 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
964 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
965 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ | |
966 | LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ | |
967 | LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ | |
968 | LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) | |
fde8b34a | 969 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_tree_ref, |
1f1ec4ed MJ |
970 | |
971 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
972 | const struct btrfs_delayed_ref_node *ref, | |
973 | const struct btrfs_delayed_tree_ref *full_ref, | |
974 | int action), | |
975 | ||
976 | TP_ARGS(fs_info, ref, full_ref, action), | |
977 | ||
978 | TP_FIELDS( | |
9d2f1147 | 979 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
1f1ec4ed MJ |
980 | ctf_integer(u64, bytenr, ref->bytenr) |
981 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
982 | ctf_integer(int, action, action) | |
983 | ctf_integer(u64, parent, full_ref->parent) | |
984 | ctf_integer(u64, ref_root, full_ref->root) | |
985 | ctf_integer(int, level, full_ref->level) | |
986 | ctf_integer(int, type, ref->type) | |
987 | ctf_integer(u64, seq, ref->seq) | |
988 | ) | |
989 | ) | |
fde8b34a | 990 | |
426eff93 MD |
991 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
992 | ||
993 | add_delayed_tree_ref, | |
994 | ||
995 | btrfs_add_delayed_tree_ref, | |
fde8b34a MJ |
996 | |
997 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
998 | const struct btrfs_delayed_ref_node *ref, | |
999 | const struct btrfs_delayed_tree_ref *full_ref, | |
1000 | int action), | |
1001 | ||
1002 | TP_ARGS(fs_info, ref, full_ref, action) | |
1003 | ) | |
1004 | ||
426eff93 MD |
1005 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1006 | ||
1007 | run_delayed_tree_ref, | |
1008 | ||
1009 | btrfs_run_delayed_tree_ref, | |
fde8b34a MJ |
1010 | |
1011 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1012 | const struct btrfs_delayed_ref_node *ref, | |
1013 | const struct btrfs_delayed_tree_ref *full_ref, | |
1014 | int action), | |
1015 | ||
1016 | TP_ARGS(fs_info, ref, full_ref, action) | |
1017 | ) | |
5f4c791e | 1018 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,8,0)) |
fde8b34a | 1019 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_tree_ref, |
fcd0a11c MD |
1020 | |
1021 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1022 | struct btrfs_delayed_ref_node *ref, | |
1023 | struct btrfs_delayed_tree_ref *full_ref, | |
1024 | int action), | |
1025 | ||
1026 | TP_ARGS(fs_info, ref, full_ref, action), | |
1027 | ||
1028 | TP_FIELDS( | |
9d2f1147 | 1029 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
fcd0a11c MD |
1030 | ctf_integer(u64, bytenr, ref->bytenr) |
1031 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1032 | ctf_integer(int, action, action) | |
1033 | ctf_integer(u64, parent, full_ref->parent) | |
1034 | ctf_integer(u64, ref_root, full_ref->root) | |
1035 | ctf_integer(int, level, full_ref->level) | |
1036 | ctf_integer(int, type, ref->type) | |
1037 | ctf_integer(u64, seq, ref->seq) | |
1038 | ) | |
1039 | ) | |
fde8b34a | 1040 | |
426eff93 MD |
1041 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1042 | ||
1043 | add_delayed_tree_ref, | |
1044 | ||
1045 | btrfs_add_delayed_tree_ref, | |
fde8b34a MJ |
1046 | |
1047 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1048 | struct btrfs_delayed_ref_node *ref, | |
1049 | struct btrfs_delayed_tree_ref *full_ref, | |
1050 | int action), | |
1051 | ||
1052 | TP_ARGS(fs_info, ref, full_ref, action) | |
1053 | ) | |
1054 | ||
426eff93 MD |
1055 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1056 | ||
1057 | run_delayed_tree_ref, | |
1058 | ||
1059 | btrfs_run_delayed_tree_ref, | |
fde8b34a MJ |
1060 | |
1061 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1062 | struct btrfs_delayed_ref_node *ref, | |
1063 | struct btrfs_delayed_tree_ref *full_ref, | |
1064 | int action), | |
1065 | ||
1066 | TP_ARGS(fs_info, ref, full_ref, action) | |
1067 | ) | |
0badc02f MJ |
1068 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,92,0,0, 4,5,0,0,0,0)) |
1069 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_tree_ref, | |
1070 | ||
1071 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1072 | const struct btrfs_delayed_tree_ref *full_ref, | |
1073 | int action), | |
1074 | ||
1075 | TP_ARGS(ref, full_ref, action), | |
1076 | ||
1077 | TP_FIELDS( | |
1078 | ctf_integer(u64, bytenr, ref->bytenr) | |
1079 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1080 | ctf_integer(int, action, action) | |
1081 | ctf_integer(u64, parent, full_ref->parent) | |
1082 | ctf_integer(u64, ref_root, full_ref->root) | |
1083 | ctf_integer(int, level, full_ref->level) | |
1084 | ctf_integer(int, type, ref->type) | |
1085 | ctf_integer(u64, seq, ref->seq) | |
1086 | ) | |
1087 | ) | |
1088 | ||
426eff93 MD |
1089 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1090 | ||
1091 | add_delayed_tree_ref, | |
1092 | ||
1093 | btrfs_add_delayed_tree_ref, | |
0badc02f MJ |
1094 | |
1095 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1096 | const struct btrfs_delayed_tree_ref *full_ref, | |
1097 | int action), | |
1098 | ||
1099 | TP_ARGS(ref, full_ref, action) | |
1100 | ) | |
1101 | ||
426eff93 MD |
1102 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1103 | ||
1104 | run_delayed_tree_ref, | |
1105 | ||
1106 | btrfs_run_delayed_tree_ref, | |
0badc02f MJ |
1107 | |
1108 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1109 | const struct btrfs_delayed_tree_ref *full_ref, | |
1110 | int action), | |
1111 | ||
1112 | TP_ARGS(ref, full_ref, action) | |
1113 | ) | |
3b67cf3e | 1114 | #else |
fde8b34a MJ |
1115 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_tree_ref, |
1116 | ||
1117 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1118 | struct btrfs_delayed_tree_ref *full_ref, | |
1119 | int action), | |
1120 | ||
1121 | TP_ARGS(ref, full_ref, action), | |
1122 | ||
1123 | TP_FIELDS( | |
1124 | ctf_integer(u64, bytenr, ref->bytenr) | |
1125 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1126 | ctf_integer(int, action, action) | |
1127 | ctf_integer(u64, parent, full_ref->parent) | |
1128 | ctf_integer(u64, ref_root, full_ref->root) | |
1129 | ctf_integer(int, level, full_ref->level) | |
1130 | ctf_integer(int, type, ref->type) | |
1131 | ctf_integer(u64, seq, ref->seq) | |
1132 | ) | |
1133 | ) | |
1134 | ||
426eff93 MD |
1135 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1136 | ||
1137 | add_delayed_tree_ref, | |
1138 | ||
1139 | btrfs_add_delayed_tree_ref, | |
fde8b34a MJ |
1140 | |
1141 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1142 | struct btrfs_delayed_tree_ref *full_ref, | |
1143 | int action), | |
1144 | ||
1145 | TP_ARGS(ref, full_ref, action) | |
1146 | ) | |
1147 | ||
426eff93 MD |
1148 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_tree_ref, |
1149 | ||
1150 | run_delayed_tree_ref, | |
1151 | ||
1152 | btrfs_run_delayed_tree_ref, | |
fde8b34a MJ |
1153 | |
1154 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1155 | struct btrfs_delayed_tree_ref *full_ref, | |
1156 | int action), | |
1157 | ||
1158 | TP_ARGS(ref, full_ref, action) | |
1159 | ) | |
fcd0a11c | 1160 | #endif |
b87700e3 | 1161 | |
5f4c791e | 1162 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
1163 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1164 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1165 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
1166 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ | |
1167 | LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ | |
1168 | LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ | |
1169 | LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) | |
fde8b34a MJ |
1170 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_data_ref, |
1171 | ||
1172 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1173 | const struct btrfs_delayed_ref_node *ref, | |
1174 | const struct btrfs_delayed_data_ref *full_ref, | |
1175 | int action), | |
1176 | ||
1177 | TP_ARGS(fs_info, ref, full_ref, action), | |
1178 | ||
1179 | TP_FIELDS( | |
9d2f1147 | 1180 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
fde8b34a MJ |
1181 | ctf_integer(u64, bytenr, ref->bytenr) |
1182 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1183 | ctf_integer(int, action, action) | |
1184 | ctf_integer(u64, parent, full_ref->parent) | |
1185 | ctf_integer(u64, ref_root, full_ref->root) | |
1186 | ctf_integer(u64, owner, full_ref->objectid) | |
1187 | ctf_integer(u64, offset, full_ref->offset) | |
1188 | ctf_integer(int, type, ref->type) | |
1189 | ctf_integer(u64, seq, ref->seq) | |
1190 | ) | |
1191 | ) | |
1192 | ||
426eff93 MD |
1193 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1194 | ||
1195 | add_delayed_data_ref, | |
1196 | ||
1197 | btrfs_add_delayed_data_ref, | |
fde8b34a MJ |
1198 | |
1199 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1200 | const struct btrfs_delayed_ref_node *ref, | |
1201 | const struct btrfs_delayed_data_ref *full_ref, | |
1202 | int action), | |
1203 | ||
1204 | TP_ARGS(fs_info, ref, full_ref, action) | |
1205 | ) | |
1206 | ||
426eff93 MD |
1207 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1208 | ||
1209 | run_delayed_data_ref, | |
1210 | ||
1211 | btrfs_run_delayed_data_ref, | |
fde8b34a MJ |
1212 | |
1213 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1214 | const struct btrfs_delayed_ref_node *ref, | |
1215 | const struct btrfs_delayed_data_ref *full_ref, | |
1216 | int action), | |
1217 | ||
1218 | TP_ARGS(fs_info, ref, full_ref, action) | |
1219 | ) | |
5f4c791e | 1220 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,8,0)) |
fde8b34a MJ |
1221 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_data_ref, |
1222 | ||
1223 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1224 | struct btrfs_delayed_ref_node *ref, | |
1225 | struct btrfs_delayed_data_ref *full_ref, | |
1226 | int action), | |
1227 | ||
1228 | TP_ARGS(fs_info, ref, full_ref, action), | |
1229 | ||
1230 | TP_FIELDS( | |
9d2f1147 | 1231 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
fde8b34a MJ |
1232 | ctf_integer(u64, bytenr, ref->bytenr) |
1233 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1234 | ctf_integer(int, action, action) | |
1235 | ctf_integer(u64, parent, full_ref->parent) | |
1236 | ctf_integer(u64, ref_root, full_ref->root) | |
1237 | ctf_integer(u64, owner, full_ref->objectid) | |
1238 | ctf_integer(u64, offset, full_ref->offset) | |
1239 | ctf_integer(int, type, ref->type) | |
1240 | ctf_integer(u64, seq, ref->seq) | |
1241 | ) | |
1242 | ) | |
1243 | ||
426eff93 MD |
1244 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1245 | ||
1246 | add_delayed_data_ref, | |
1247 | ||
1248 | btrfs_add_delayed_data_ref, | |
fde8b34a MJ |
1249 | |
1250 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1251 | struct btrfs_delayed_ref_node *ref, | |
1252 | struct btrfs_delayed_data_ref *full_ref, | |
1253 | int action), | |
1254 | ||
1255 | TP_ARGS(fs_info, ref, full_ref, action) | |
1256 | ) | |
1257 | ||
426eff93 MD |
1258 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1259 | ||
1260 | run_delayed_data_ref, | |
1261 | ||
1262 | btrfs_run_delayed_data_ref, | |
fde8b34a MJ |
1263 | |
1264 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1265 | struct btrfs_delayed_ref_node *ref, | |
1266 | struct btrfs_delayed_data_ref *full_ref, | |
1267 | int action), | |
1268 | ||
1269 | TP_ARGS(fs_info, ref, full_ref, action) | |
1270 | ) | |
0badc02f MJ |
1271 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,92,0,0, 4,5,0,0,0,0)) |
1272 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_data_ref, | |
1273 | ||
1274 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1275 | const struct btrfs_delayed_data_ref *full_ref, | |
1276 | int action), | |
1277 | ||
1278 | TP_ARGS(ref, full_ref, action), | |
1279 | ||
1280 | TP_FIELDS( | |
1281 | ctf_integer(u64, bytenr, ref->bytenr) | |
1282 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1283 | ctf_integer(int, action, action) | |
1284 | ctf_integer(u64, parent, full_ref->parent) | |
1285 | ctf_integer(u64, ref_root, full_ref->root) | |
1286 | ctf_integer(u64, owner, full_ref->objectid) | |
1287 | ctf_integer(u64, offset, full_ref->offset) | |
1288 | ctf_integer(int, type, ref->type) | |
1289 | ctf_integer(u64, seq, ref->seq) | |
1290 | ) | |
1291 | ) | |
1292 | ||
426eff93 MD |
1293 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1294 | ||
1295 | add_delayed_data_ref, | |
1296 | ||
1297 | btrfs_add_delayed_data_ref, | |
0badc02f MJ |
1298 | |
1299 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1300 | const struct btrfs_delayed_data_ref *full_ref, | |
1301 | int action), | |
1302 | ||
1303 | TP_ARGS(fs_info, ref, full_ref, action) | |
1304 | ) | |
1305 | ||
426eff93 MD |
1306 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1307 | ||
1308 | run_delayed_data_ref, | |
1309 | ||
1310 | btrfs_run_delayed_data_ref, | |
0badc02f MJ |
1311 | |
1312 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1313 | const struct btrfs_delayed_data_ref *full_ref, | |
1314 | int action), | |
1315 | ||
1316 | TP_ARGS(fs_info, ref, full_ref, action) | |
1317 | ) | |
3b67cf3e | 1318 | #else |
fde8b34a MJ |
1319 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_data_ref, |
1320 | ||
1321 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1322 | struct btrfs_delayed_data_ref *full_ref, | |
1323 | int action), | |
1324 | ||
1325 | TP_ARGS(ref, full_ref, action), | |
1326 | ||
1327 | TP_FIELDS( | |
1328 | ctf_integer(u64, bytenr, ref->bytenr) | |
1329 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1330 | ctf_integer(int, action, action) | |
1331 | ctf_integer(u64, parent, full_ref->parent) | |
1332 | ctf_integer(u64, ref_root, full_ref->root) | |
1333 | ctf_integer(u64, owner, full_ref->objectid) | |
1334 | ctf_integer(u64, offset, full_ref->offset) | |
1335 | ctf_integer(int, type, ref->type) | |
1336 | ctf_integer(u64, seq, ref->seq) | |
1337 | ) | |
1338 | ) | |
1339 | ||
426eff93 MD |
1340 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1341 | ||
1342 | add_delayed_data_ref, | |
1343 | ||
1344 | btrfs_add_delayed_data_ref, | |
fde8b34a MJ |
1345 | |
1346 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1347 | struct btrfs_delayed_data_ref *full_ref, | |
1348 | int action), | |
1349 | ||
1350 | TP_ARGS(fs_info, ref, full_ref, action) | |
1351 | ) | |
1352 | ||
426eff93 MD |
1353 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_data_ref, |
1354 | ||
1355 | run_delayed_data_ref, | |
1356 | ||
1357 | btrfs_run_delayed_data_ref, | |
fde8b34a MJ |
1358 | |
1359 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1360 | struct btrfs_delayed_data_ref *full_ref, | |
1361 | int action), | |
1362 | ||
1363 | TP_ARGS(fs_info, ref, full_ref, action) | |
1364 | ) | |
fde8b34a | 1365 | #endif |
b87700e3 | 1366 | |
5f4c791e | 1367 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,15,0)) |
ab9ebe67 MJ |
1368 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, |
1369 | ||
1370 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1371 | const struct btrfs_delayed_ref_head *head_ref, | |
1372 | int action), | |
1373 | ||
1374 | TP_ARGS(fs_info, head_ref, action), | |
1375 | ||
1376 | TP_FIELDS( | |
1377 | ctf_integer(u64, bytenr, head_ref->bytenr) | |
1378 | ctf_integer(u64, num_bytes, head_ref->num_bytes) | |
1379 | ctf_integer(int, action, action) | |
1380 | ctf_integer(int, is_data, head_ref->is_data) | |
1381 | ) | |
1382 | ) | |
1383 | ||
d7921a5f MD |
1384 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1385 | ||
1386 | add_delayed_ref_head, | |
1387 | ||
1388 | btrfs_add_delayed_ref_head, | |
ab9ebe67 MJ |
1389 | |
1390 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1391 | const struct btrfs_delayed_ref_head *head_ref, | |
1392 | int action), | |
1393 | ||
1394 | TP_ARGS(fs_info, head_ref, action) | |
1395 | ) | |
1396 | ||
d7921a5f MD |
1397 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1398 | ||
1399 | run_delayed_ref_head, | |
1400 | ||
1401 | btrfs_run_delayed_ref_head, | |
ab9ebe67 MJ |
1402 | |
1403 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1404 | const struct btrfs_delayed_ref_head *head_ref, | |
1405 | int action), | |
1406 | ||
1407 | TP_ARGS(fs_info, head_ref, action) | |
1408 | ) | |
1409 | ||
5f4c791e | 1410 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
1411 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1412 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1413 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
1414 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ | |
1415 | LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ | |
1416 | LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ | |
1417 | LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) | |
1418 | ||
ab9ebe67 MJ |
1419 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, |
1420 | ||
1421 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1422 | const struct btrfs_delayed_ref_node *ref, | |
1423 | const struct btrfs_delayed_ref_head *head_ref, | |
1424 | int action), | |
1425 | ||
1426 | TP_ARGS(fs_info, ref, head_ref, action), | |
1427 | ||
1428 | TP_FIELDS( | |
1429 | ctf_integer(u64, bytenr, ref->bytenr) | |
1430 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1431 | ctf_integer(int, action, action) | |
1432 | ctf_integer(int, is_data, head_ref->is_data) | |
1433 | ) | |
1434 | ) | |
1435 | ||
d7921a5f MD |
1436 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1437 | ||
1438 | add_delayed_ref_head, | |
1439 | ||
1440 | btrfs_add_delayed_ref_head, | |
ab9ebe67 MJ |
1441 | |
1442 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1443 | const struct btrfs_delayed_ref_node *ref, | |
1444 | const struct btrfs_delayed_ref_head *head_ref, | |
1445 | int action), | |
1446 | ||
1447 | TP_ARGS(fs_info, ref, head_ref, action) | |
1448 | ) | |
1449 | ||
d7921a5f MD |
1450 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1451 | ||
1452 | run_delayed_ref_head, | |
1453 | ||
1454 | btrfs_run_delayed_ref_head, | |
ab9ebe67 MJ |
1455 | |
1456 | TP_PROTO(const struct btrfs_fs_info *fs_info, | |
1457 | const struct btrfs_delayed_ref_node *ref, | |
1458 | const struct btrfs_delayed_ref_head *head_ref, | |
1459 | int action), | |
1460 | ||
1461 | TP_ARGS(fs_info, ref, head_ref, action) | |
1462 | ) | |
1463 | ||
5f4c791e | 1464 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,8,0)) |
ab9ebe67 | 1465 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, |
fcd0a11c MD |
1466 | |
1467 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1468 | struct btrfs_delayed_ref_node *ref, | |
1469 | struct btrfs_delayed_ref_head *head_ref, | |
1470 | int action), | |
1471 | ||
1472 | TP_ARGS(fs_info, ref, head_ref, action), | |
1473 | ||
1474 | TP_FIELDS( | |
1475 | ctf_integer(u64, bytenr, ref->bytenr) | |
1476 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1477 | ctf_integer(int, action, action) | |
1478 | ctf_integer(int, is_data, head_ref->is_data) | |
1479 | ) | |
1480 | ) | |
1481 | ||
d7921a5f MD |
1482 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1483 | ||
1484 | add_delayed_ref_head, | |
1485 | ||
1486 | btrfs_add_delayed_ref_head, | |
ab9ebe67 MJ |
1487 | |
1488 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1489 | struct btrfs_delayed_ref_node *ref, | |
1490 | struct btrfs_delayed_ref_head *head_ref, | |
1491 | int action), | |
1492 | ||
1493 | TP_ARGS(fs_info, ref, head_ref, action) | |
1494 | ) | |
1495 | ||
d7921a5f MD |
1496 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1497 | ||
1498 | run_delayed_ref_head, | |
1499 | ||
1500 | btrfs_run_delayed_ref_head, | |
ab9ebe67 MJ |
1501 | |
1502 | TP_PROTO(struct btrfs_fs_info *fs_info, | |
1503 | struct btrfs_delayed_ref_node *ref, | |
1504 | struct btrfs_delayed_ref_head *head_ref, | |
1505 | int action), | |
1506 | ||
1507 | TP_ARGS(fs_info, ref, head_ref, action) | |
1508 | ) | |
1509 | ||
0badc02f | 1510 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,92,0,0, 4,5,0,0,0,0)) |
0b3f6dcb MJ |
1511 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, |
1512 | ||
1513 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1514 | const struct btrfs_delayed_ref_head *head_ref, | |
1515 | int action), | |
1516 | ||
1517 | TP_ARGS(ref, head_ref, action), | |
1518 | ||
1519 | TP_FIELDS( | |
1520 | ctf_integer(u64, bytenr, ref->bytenr) | |
1521 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1522 | ctf_integer(int, action, action) | |
1523 | ctf_integer(int, is_data, head_ref->is_data) | |
1524 | ) | |
1525 | ) | |
1526 | ||
d7921a5f MD |
1527 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1528 | ||
1529 | add_delayed_ref_head, | |
1530 | ||
1531 | btrfs_add_delayed_ref_head, | |
0b3f6dcb MJ |
1532 | |
1533 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1534 | const struct btrfs_delayed_ref_head *head_ref, | |
1535 | int action), | |
1536 | ||
1537 | TP_ARGS(ref, head_ref, action) | |
1538 | ) | |
1539 | ||
d7921a5f MD |
1540 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1541 | ||
1542 | run_delayed_ref_head, | |
1543 | ||
1544 | btrfs_run_delayed_ref_head, | |
0b3f6dcb MJ |
1545 | |
1546 | TP_PROTO(const struct btrfs_delayed_ref_node *ref, | |
1547 | const struct btrfs_delayed_ref_head *head_ref, | |
1548 | int action), | |
1549 | ||
1550 | TP_ARGS(ref, head_ref, action) | |
1551 | ) | |
1552 | ||
3b67cf3e | 1553 | #else |
ab9ebe67 MJ |
1554 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, |
1555 | ||
1556 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1557 | struct btrfs_delayed_ref_head *head_ref, | |
1558 | int action), | |
1559 | ||
1560 | TP_ARGS(ref, head_ref, action), | |
1561 | ||
1562 | TP_FIELDS( | |
1563 | ctf_integer(u64, bytenr, ref->bytenr) | |
1564 | ctf_integer(u64, num_bytes, ref->num_bytes) | |
1565 | ctf_integer(int, action, action) | |
1566 | ctf_integer(int, is_data, head_ref->is_data) | |
1567 | ) | |
1568 | ) | |
1569 | ||
d7921a5f MD |
1570 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1571 | ||
1572 | add_delayed_ref_head, | |
1573 | ||
1574 | btrfs_add_delayed_ref_head, | |
ab9ebe67 MJ |
1575 | |
1576 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1577 | struct btrfs_delayed_ref_head *head_ref, | |
1578 | int action), | |
1579 | ||
1580 | TP_ARGS(ref, head_ref, action) | |
1581 | ) | |
1582 | ||
d7921a5f MD |
1583 | LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, |
1584 | ||
1585 | run_delayed_ref_head, | |
1586 | ||
1587 | btrfs_run_delayed_ref_head, | |
ab9ebe67 MJ |
1588 | |
1589 | TP_PROTO(struct btrfs_delayed_ref_node *ref, | |
1590 | struct btrfs_delayed_ref_head *head_ref, | |
1591 | int action), | |
1592 | ||
1593 | TP_ARGS(ref, head_ref, action) | |
1594 | ) | |
fcd0a11c | 1595 | #endif |
b87700e3 | 1596 | |
a24df612 KS |
1597 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,8,0)) |
1598 | ||
1599 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, | |
1600 | ||
1601 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_chunk_map *map, | |
1602 | u64 offset, u64 size), | |
1603 | ||
1604 | TP_ARGS(fs_info, map, offset, size), | |
1605 | ||
1606 | TP_FIELDS( | |
1607 | ctf_integer(int, num_stripes, map->num_stripes) | |
1608 | ctf_integer(u64, type, map->type) | |
1609 | ctf_integer(int, sub_stripes, map->sub_stripes) | |
1610 | ctf_integer(u64, offset, offset) | |
1611 | ctf_integer(u64, size, size) | |
1612 | ctf_integer(u64, root_objectid, fs_info->chunk_root->root_key.objectid) | |
1613 | ) | |
1614 | ) | |
1615 | ||
1616 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_alloc, | |
1617 | ||
1618 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_chunk_map *map, | |
1619 | u64 offset, u64 size), | |
1620 | ||
1621 | TP_ARGS(fs_info, map, offset, size) | |
1622 | ) | |
1623 | ||
1624 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, | |
1625 | ||
1626 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_chunk_map *map, | |
1627 | u64 offset, u64 size), | |
1628 | ||
1629 | TP_ARGS(fs_info, map, offset, size) | |
1630 | ) | |
1631 | ||
1632 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) | |
1f1ec4ed MJ |
1633 | |
1634 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, | |
1635 | ||
1636 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct map_lookup *map, | |
1637 | u64 offset, u64 size), | |
1638 | ||
1639 | TP_ARGS(fs_info, map, offset, size), | |
1640 | ||
1641 | TP_FIELDS( | |
1642 | ctf_integer(int, num_stripes, map->num_stripes) | |
1643 | ctf_integer(u64, type, map->type) | |
1644 | ctf_integer(int, sub_stripes, map->sub_stripes) | |
1645 | ctf_integer(u64, offset, offset) | |
1646 | ctf_integer(u64, size, size) | |
1647 | ctf_integer(u64, root_objectid, fs_info->chunk_root->root_key.objectid) | |
1648 | ) | |
1649 | ) | |
1650 | ||
1651 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_alloc, | |
1652 | ||
9d2f1147 | 1653 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct map_lookup *map, |
1f1ec4ed MJ |
1654 | u64 offset, u64 size), |
1655 | ||
9d2f1147 | 1656 | TP_ARGS(fs_info, map, offset, size) |
1f1ec4ed MJ |
1657 | ) |
1658 | ||
1659 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, | |
1660 | ||
9d2f1147 | 1661 | TP_PROTO(const struct btrfs_fs_info *fs_info, const struct map_lookup *map, |
1f1ec4ed MJ |
1662 | u64 offset, u64 size), |
1663 | ||
9d2f1147 | 1664 | TP_ARGS(fs_info, map, offset, size) |
1f1ec4ed MJ |
1665 | ) |
1666 | ||
5f4c791e | 1667 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) |
ff8bdcc2 MD |
1668 | |
1669 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, | |
1670 | ||
1671 | TP_PROTO(struct btrfs_fs_info *fs_info, struct map_lookup *map, | |
1672 | u64 offset, u64 size), | |
1673 | ||
1674 | TP_ARGS(fs_info, map, offset, size), | |
1675 | ||
1676 | TP_FIELDS( | |
1677 | ctf_integer(int, num_stripes, map->num_stripes) | |
1678 | ctf_integer(u64, type, map->type) | |
1679 | ctf_integer(int, sub_stripes, map->sub_stripes) | |
1680 | ctf_integer(u64, offset, offset) | |
1681 | ctf_integer(u64, size, size) | |
1682 | ctf_integer(u64, root_objectid, fs_info->chunk_root->root_key.objectid) | |
1683 | ) | |
1684 | ) | |
1685 | ||
1686 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_alloc, | |
1687 | ||
9d2f1147 | 1688 | TP_PROTO(struct btrfs_fs_info *fs_info, struct map_lookup *map, |
ff8bdcc2 MD |
1689 | u64 offset, u64 size), |
1690 | ||
9d2f1147 | 1691 | TP_ARGS(fs_info, map, offset, size) |
ff8bdcc2 MD |
1692 | ) |
1693 | ||
1694 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, | |
1695 | ||
9d2f1147 | 1696 | TP_PROTO(struct btrfs_fs_info *fs_info, struct map_lookup *map, |
ff8bdcc2 MD |
1697 | u64 offset, u64 size), |
1698 | ||
9d2f1147 | 1699 | TP_ARGS(fs_info, map, offset, size) |
ff8bdcc2 MD |
1700 | ) |
1701 | ||
0badc02f MJ |
1702 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1703 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1704 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
1705 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
7ca7cd6e MJ |
1706 | |
1707 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, | |
1708 | ||
1709 | TP_PROTO(const struct btrfs_root *root, const struct map_lookup *map, | |
1710 | u64 offset, u64 size), | |
1711 | ||
1712 | TP_ARGS(root, map, offset, size), | |
1713 | ||
1714 | TP_FIELDS( | |
1715 | ctf_integer(int, num_stripes, map->num_stripes) | |
1716 | ctf_integer(u64, type, map->type) | |
1717 | ctf_integer(int, sub_stripes, map->sub_stripes) | |
1718 | ctf_integer(u64, offset, offset) | |
1719 | ctf_integer(u64, size, size) | |
1720 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1721 | ) | |
1722 | ) | |
1723 | ||
1724 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_alloc, | |
1725 | ||
1726 | TP_PROTO(const struct btrfs_root *root, const struct map_lookup *map, | |
1727 | u64 offset, u64 size), | |
1728 | ||
1729 | TP_ARGS(root, map, offset, size) | |
1730 | ) | |
1731 | ||
1732 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, | |
1733 | ||
1734 | TP_PROTO(const struct btrfs_root *root, const struct map_lookup *map, | |
1735 | u64 offset, u64 size), | |
1736 | ||
1737 | TP_ARGS(root, map, offset, size) | |
1738 | ) | |
1739 | ||
5f4c791e | 1740 | #else /* #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
ff8bdcc2 | 1741 | |
3bc29f0a | 1742 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, |
b87700e3 AG |
1743 | |
1744 | TP_PROTO(struct btrfs_root *root, struct map_lookup *map, | |
1745 | u64 offset, u64 size), | |
1746 | ||
1747 | TP_ARGS(root, map, offset, size), | |
1748 | ||
f127e61e MD |
1749 | TP_FIELDS( |
1750 | ctf_integer(int, num_stripes, map->num_stripes) | |
1751 | ctf_integer(u64, type, map->type) | |
1752 | ctf_integer(int, sub_stripes, map->sub_stripes) | |
1753 | ctf_integer(u64, offset, offset) | |
1754 | ctf_integer(u64, size, size) | |
1755 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1756 | ) | |
b87700e3 AG |
1757 | ) |
1758 | ||
3bc29f0a | 1759 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_alloc, |
b87700e3 AG |
1760 | |
1761 | TP_PROTO(struct btrfs_root *root, struct map_lookup *map, | |
1762 | u64 offset, u64 size), | |
1763 | ||
1764 | TP_ARGS(root, map, offset, size) | |
1765 | ) | |
1766 | ||
3bc29f0a | 1767 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, |
b87700e3 AG |
1768 | |
1769 | TP_PROTO(struct btrfs_root *root, struct map_lookup *map, | |
1770 | u64 offset, u64 size), | |
1771 | ||
1772 | TP_ARGS(root, map, offset, size) | |
1773 | ) | |
1774 | ||
5f4c791e | 1775 | #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
ff8bdcc2 | 1776 | |
5f4c791e | 1777 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
1778 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1779 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1780 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 1781 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
1782 | LTTNG_TRACEPOINT_EVENT(btrfs_cow_block, |
1783 | ||
1784 | TP_PROTO(const struct btrfs_root *root, const struct extent_buffer *buf, | |
1785 | const struct extent_buffer *cow), | |
1786 | ||
1787 | TP_ARGS(root, buf, cow), | |
1788 | ||
1789 | TP_FIELDS( | |
1790 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1791 | ctf_integer(u64, buf_start, buf->start) | |
1792 | ctf_integer(int, refs, atomic_read(&buf->refs)) | |
1793 | ctf_integer(u64, cow_start, cow->start) | |
1794 | ctf_integer(int, buf_level, btrfs_header_level(buf)) | |
1795 | ctf_integer(int, cow_level, btrfs_header_level(cow)) | |
1796 | ) | |
1797 | ) | |
1798 | #else | |
3bc29f0a | 1799 | LTTNG_TRACEPOINT_EVENT(btrfs_cow_block, |
b87700e3 AG |
1800 | |
1801 | TP_PROTO(struct btrfs_root *root, struct extent_buffer *buf, | |
1802 | struct extent_buffer *cow), | |
1803 | ||
1804 | TP_ARGS(root, buf, cow), | |
1805 | ||
f127e61e MD |
1806 | TP_FIELDS( |
1807 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1808 | ctf_integer(u64, buf_start, buf->start) | |
1809 | ctf_integer(int, refs, atomic_read(&buf->refs)) | |
1810 | ctf_integer(u64, cow_start, cow->start) | |
1811 | ctf_integer(int, buf_level, btrfs_header_level(buf)) | |
1812 | ctf_integer(int, cow_level, btrfs_header_level(cow)) | |
1813 | ) | |
b87700e3 | 1814 | ) |
1f1ec4ed | 1815 | #endif |
b87700e3 | 1816 | |
5f4c791e | 1817 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
ae5af8ea MJ |
1818 | LTTNG_TRACEPOINT_EVENT(btrfs_space_reservation, |
1819 | ||
1820 | TP_PROTO(const struct btrfs_fs_info *fs_info, const char *type, u64 val, | |
1821 | u64 bytes, int reserve), | |
1822 | ||
1823 | TP_ARGS(fs_info, type, val, bytes, reserve), | |
1824 | ||
1825 | TP_FIELDS( | |
1826 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
1827 | ctf_string(type, type) | |
1828 | ctf_integer(u64, val, val) | |
1829 | ctf_integer(u64, bytes, bytes) | |
1830 | ctf_integer(int, reserve, reserve) | |
1831 | ) | |
1832 | ) | |
5f4c791e | 1833 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
1834 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1835 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1836 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 1837 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
1838 | LTTNG_TRACEPOINT_EVENT(btrfs_space_reservation, |
1839 | ||
1840 | TP_PROTO(const struct btrfs_fs_info *fs_info, char *type, u64 val, | |
1841 | u64 bytes, int reserve), | |
1842 | ||
1843 | TP_ARGS(fs_info, type, val, bytes, reserve), | |
1844 | ||
1845 | TP_FIELDS( | |
9d2f1147 | 1846 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
1f1ec4ed MJ |
1847 | ctf_string(type, type) |
1848 | ctf_integer(u64, val, val) | |
1849 | ctf_integer(u64, bytes, bytes) | |
1850 | ctf_integer(int, reserve, reserve) | |
1851 | ) | |
1852 | ) | |
3b67cf3e | 1853 | #else |
3bc29f0a | 1854 | LTTNG_TRACEPOINT_EVENT(btrfs_space_reservation, |
b87700e3 AG |
1855 | |
1856 | TP_PROTO(struct btrfs_fs_info *fs_info, char *type, u64 val, | |
1857 | u64 bytes, int reserve), | |
1858 | ||
1859 | TP_ARGS(fs_info, type, val, bytes, reserve), | |
1860 | ||
f127e61e | 1861 | TP_FIELDS( |
9d2f1147 | 1862 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
f127e61e MD |
1863 | ctf_string(type, type) |
1864 | ctf_integer(u64, val, val) | |
1865 | ctf_integer(u64, bytes, bytes) | |
1866 | ctf_integer(int, reserve, reserve) | |
1867 | ) | |
b87700e3 AG |
1868 | ) |
1869 | #endif | |
1870 | ||
5f4c791e | 1871 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) |
1f1ec4ed MJ |
1872 | |
1873 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserved_extent, | |
1874 | ||
9d2f1147 | 1875 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 start, u64 len), |
1f1ec4ed | 1876 | |
9d2f1147 | 1877 | TP_ARGS(fs_info, start, len), |
1f1ec4ed MJ |
1878 | |
1879 | TP_FIELDS( | |
1880 | ctf_integer(u64, start, start) | |
1881 | ctf_integer(u64, len, len) | |
1882 | ) | |
1883 | ) | |
1884 | ||
1885 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_alloc, | |
1886 | ||
9d2f1147 | 1887 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 start, u64 len), |
1f1ec4ed | 1888 | |
9d2f1147 | 1889 | TP_ARGS(fs_info, start, len) |
1f1ec4ed MJ |
1890 | ) |
1891 | ||
1892 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_free, | |
1893 | ||
9d2f1147 | 1894 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 start, u64 len), |
1f1ec4ed | 1895 | |
9d2f1147 | 1896 | TP_ARGS(fs_info, start, len) |
1f1ec4ed MJ |
1897 | ) |
1898 | ||
5f4c791e | 1899 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) |
ff8bdcc2 MD |
1900 | |
1901 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserved_extent, | |
1902 | ||
9d2f1147 | 1903 | TP_PROTO(struct btrfs_fs_info *fs_info, u64 start, u64 len), |
ff8bdcc2 | 1904 | |
9d2f1147 | 1905 | TP_ARGS(fs_info, start, len), |
ff8bdcc2 MD |
1906 | |
1907 | TP_FIELDS( | |
1908 | ctf_integer(u64, start, start) | |
1909 | ctf_integer(u64, len, len) | |
1910 | ) | |
1911 | ) | |
1912 | ||
1913 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_alloc, | |
1914 | ||
9d2f1147 | 1915 | TP_PROTO(struct btrfs_fs_info *fs_info, u64 start, u64 len), |
ff8bdcc2 | 1916 | |
9d2f1147 | 1917 | TP_ARGS(fs_info, start, len) |
ff8bdcc2 MD |
1918 | ) |
1919 | ||
1920 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_free, | |
1921 | ||
9d2f1147 | 1922 | TP_PROTO(struct btrfs_fs_info *fs_info, u64 start, u64 len), |
ff8bdcc2 | 1923 | |
9d2f1147 | 1924 | TP_ARGS(fs_info, start, len) |
ff8bdcc2 MD |
1925 | ) |
1926 | ||
0badc02f MJ |
1927 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
1928 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
1929 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
1930 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
7ca7cd6e MJ |
1931 | |
1932 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserved_extent, | |
1933 | ||
1934 | TP_PROTO(const struct btrfs_root *root, u64 start, u64 len), | |
1935 | ||
1936 | TP_ARGS(root, start, len), | |
1937 | ||
1938 | TP_FIELDS( | |
1939 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1940 | ctf_integer(u64, start, start) | |
1941 | ctf_integer(u64, len, len) | |
1942 | ) | |
1943 | ) | |
1944 | ||
1945 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_alloc, | |
1946 | ||
1947 | TP_PROTO(const struct btrfs_root *root, u64 start, u64 len), | |
1948 | ||
1949 | TP_ARGS(root, start, len) | |
1950 | ) | |
1951 | ||
1952 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_free, | |
1953 | ||
1954 | TP_PROTO(const struct btrfs_root *root, u64 start, u64 len), | |
1955 | ||
1956 | TP_ARGS(root, start, len) | |
1957 | ) | |
1958 | ||
5f4c791e | 1959 | #else /* #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
ff8bdcc2 | 1960 | |
3bc29f0a | 1961 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserved_extent, |
b87700e3 AG |
1962 | |
1963 | TP_PROTO(struct btrfs_root *root, u64 start, u64 len), | |
1964 | ||
1965 | TP_ARGS(root, start, len), | |
1966 | ||
f127e61e MD |
1967 | TP_FIELDS( |
1968 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
1969 | ctf_integer(u64, start, start) | |
1970 | ctf_integer(u64, len, len) | |
1971 | ) | |
b87700e3 AG |
1972 | ) |
1973 | ||
3bc29f0a | 1974 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_alloc, |
b87700e3 AG |
1975 | |
1976 | TP_PROTO(struct btrfs_root *root, u64 start, u64 len), | |
1977 | ||
1978 | TP_ARGS(root, start, len) | |
1979 | ) | |
1980 | ||
3bc29f0a | 1981 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_free, |
b87700e3 AG |
1982 | |
1983 | TP_PROTO(struct btrfs_root *root, u64 start, u64 len), | |
1984 | ||
1985 | TP_ARGS(root, start, len) | |
1986 | ) | |
1987 | ||
5f4c791e | 1988 | #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
ff8bdcc2 | 1989 | |
f39b4a3c MJ |
1990 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,3,0)) |
1991 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
1992 | ||
1993 | btrfs_find_free_extent, | |
1994 | ||
1995 | TP_PROTO(const struct btrfs_root *root, | |
1996 | const struct find_free_extent_ctl *ffe_ctl), | |
1997 | ||
1998 | TP_ARGS(root, ffe_ctl), | |
1999 | ||
2000 | TP_FIELDS( | |
2001 | ctf_array(u8, fsid, root->lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2002 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2003 | ctf_integer(u64, num_bytes, ffe_ctl->num_bytes) | |
2004 | ctf_integer(u64, empty_size, ffe_ctl->empty_size) | |
2005 | ctf_integer(u64, flags, ffe_ctl->flags) | |
2006 | ) | |
2007 | ) | |
2008 | ||
2009 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,10,0) || \ | |
eb270dc0 | 2010 | LTTNG_KERNEL_RANGE(5,9,5, 5,10,0) || \ |
859ad5c7 MJ |
2011 | LTTNG_KERNEL_RANGE(5,4,78, 5,5,0) || \ |
2012 | LTTNG_UBUNTU_KERNEL_RANGE(5,8,18,44, 5,9,0,0)) | |
ab1ddefc MJ |
2013 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, |
2014 | ||
2015 | btrfs_find_free_extent, | |
2016 | ||
2017 | TP_PROTO(const struct btrfs_root *root, u64 num_bytes, u64 empty_size, | |
2018 | u64 data), | |
2019 | ||
2020 | TP_ARGS(root, num_bytes, empty_size, data), | |
2021 | ||
2022 | TP_FIELDS( | |
2023 | ctf_array(u8, fsid, root->lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2024 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2025 | ctf_integer(u64, num_bytes, num_bytes) | |
2026 | ctf_integer(u64, empty_size, empty_size) | |
2027 | ctf_integer(u64, data, data) | |
2028 | ) | |
2029 | ) | |
2030 | ||
5f4c791e | 2031 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
ab1ddefc | 2032 | |
5809d816 MJ |
2033 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, |
2034 | ||
2035 | btrfs_find_free_extent, | |
2036 | ||
2037 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 num_bytes, u64 empty_size, | |
2038 | u64 data), | |
2039 | ||
2040 | TP_ARGS(fs_info, num_bytes, empty_size, data), | |
2041 | ||
2042 | TP_FIELDS( | |
2043 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2044 | ctf_integer(u64, num_bytes, num_bytes) | |
2045 | ctf_integer(u64, empty_size, empty_size) | |
2046 | ctf_integer(u64, data, data) | |
2047 | ) | |
2048 | ) | |
2049 | ||
5f4c791e | 2050 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,18,0)) |
ab1ddefc MJ |
2051 | |
2052 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
2053 | ||
2054 | btrfs_find_free_extent, | |
2055 | ||
2056 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 num_bytes, u64 empty_size, | |
2057 | u64 data), | |
2058 | ||
2059 | TP_ARGS(fs_info, num_bytes, empty_size, data), | |
2060 | ||
2061 | TP_FIELDS( | |
2062 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2063 | ctf_integer(u64, num_bytes, num_bytes) | |
2064 | ctf_integer(u64, empty_size, empty_size) | |
2065 | ctf_integer(u64, data, data) | |
2066 | ) | |
2067 | ) | |
2068 | ||
5f4c791e | 2069 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) |
ab1ddefc MJ |
2070 | |
2071 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
2072 | ||
2073 | btrfs_find_free_extent, | |
2074 | ||
2075 | TP_PROTO(const struct btrfs_fs_info *fs_info, u64 num_bytes, u64 empty_size, | |
2076 | u64 data), | |
2077 | ||
2078 | TP_ARGS(fs_info, num_bytes, empty_size, data), | |
2079 | ||
2080 | TP_FIELDS( | |
2081 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2082 | ctf_integer(u64, num_bytes, num_bytes) | |
2083 | ctf_integer(u64, empty_size, empty_size) | |
2084 | ctf_integer(u64, data, data) | |
2085 | ) | |
2086 | ) | |
2087 | ||
5f4c791e | 2088 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) |
ab1ddefc MJ |
2089 | |
2090 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
2091 | ||
2092 | btrfs_find_free_extent, | |
2093 | ||
2094 | TP_PROTO(struct btrfs_fs_info *fs_info, u64 num_bytes, u64 empty_size, | |
2095 | u64 data), | |
2096 | ||
2097 | TP_ARGS(fs_info, num_bytes, empty_size, data), | |
2098 | ||
2099 | TP_FIELDS( | |
2100 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2101 | ctf_integer(u64, num_bytes, num_bytes) | |
2102 | ctf_integer(u64, empty_size, empty_size) | |
2103 | ctf_integer(u64, data, data) | |
2104 | ) | |
2105 | ) | |
2106 | ||
2107 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ | |
2108 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
2109 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
2110 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
2111 | ||
2112 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
2113 | ||
2114 | btrfs_find_free_extent, | |
2115 | ||
2116 | TP_PROTO(const struct btrfs_root *root, u64 num_bytes, u64 empty_size, | |
2117 | u64 data), | |
2118 | ||
2119 | TP_ARGS(root, num_bytes, empty_size, data), | |
2120 | ||
2121 | TP_FIELDS( | |
2122 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2123 | ctf_integer(u64, num_bytes, num_bytes) | |
2124 | ctf_integer(u64, empty_size, empty_size) | |
2125 | ctf_integer(u64, data, data) | |
2126 | ) | |
2127 | ) | |
3b67cf3e | 2128 | #else |
ab1ddefc MJ |
2129 | |
2130 | LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, | |
2131 | ||
2132 | btrfs_find_free_extent, | |
2133 | ||
2134 | TP_PROTO(struct btrfs_root *root, u64 num_bytes, u64 empty_size, | |
2135 | u64 data), | |
2136 | ||
2137 | TP_ARGS(root, num_bytes, empty_size, data), | |
2138 | ||
2139 | TP_FIELDS( | |
2140 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2141 | ctf_integer(u64, num_bytes, num_bytes) | |
2142 | ctf_integer(u64, empty_size, empty_size) | |
2143 | ctf_integer(u64, data, data) | |
2144 | ) | |
2145 | ) | |
2146 | #endif | |
2147 | ||
f39b4a3c MJ |
2148 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,3,0)) |
2149 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, | |
2150 | ||
2151 | TP_PROTO(const struct btrfs_block_group *block_group, | |
2152 | const struct find_free_extent_ctl *ffe_ctl), | |
2153 | ||
2154 | TP_ARGS(block_group, ffe_ctl), | |
2155 | ||
2156 | TP_FIELDS( | |
2157 | ctf_array(u8, fsid, block_group->lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2158 | ctf_integer(u64, bg_objectid, block_group->start) | |
2159 | ctf_integer(u64, flags, block_group->flags) | |
2160 | ctf_integer(u64, start, ffe_ctl->search_start) | |
2161 | ctf_integer(u64, len, ffe_ctl->num_bytes) | |
2162 | ) | |
2163 | ) | |
2164 | ||
2165 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2166 | ||
2167 | TP_PROTO(const struct btrfs_block_group *block_group, | |
2168 | const struct find_free_extent_ctl *ffe_ctl), | |
2169 | ||
2170 | TP_ARGS(block_group, ffe_ctl) | |
2171 | ) | |
2172 | ||
2173 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2174 | ||
2175 | TP_PROTO(const struct btrfs_block_group *block_group, | |
2176 | const struct find_free_extent_ctl *ffe_ctl), | |
2177 | ||
2178 | TP_ARGS(block_group, ffe_ctl) | |
2179 | ) | |
2180 | ||
2181 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) | |
5809d816 MJ |
2182 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, |
2183 | ||
2184 | TP_PROTO(const struct btrfs_block_group *block_group, u64 start, | |
2185 | u64 len), | |
2186 | ||
2187 | TP_ARGS(block_group, start, len), | |
2188 | ||
2189 | TP_FIELDS( | |
2190 | ctf_array(u8, fsid, block_group->lttng_fs_info_fsid, BTRFS_UUID_SIZE) | |
2191 | ctf_integer(u64, bg_objectid, block_group->start) | |
2192 | ctf_integer(u64, flags, block_group->flags) | |
2193 | ctf_integer(u64, start, start) | |
2194 | ctf_integer(u64, len, len) | |
2195 | ) | |
2196 | ) | |
2197 | ||
2198 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2199 | ||
2200 | TP_PROTO(const struct btrfs_block_group *block_group, u64 start, | |
2201 | u64 len), | |
2202 | ||
2203 | TP_ARGS(block_group, start, len) | |
2204 | ) | |
2205 | ||
2206 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2207 | ||
2208 | TP_PROTO(const struct btrfs_block_group *block_group, u64 start, | |
2209 | u64 len), | |
2210 | ||
2211 | TP_ARGS(block_group, start, len) | |
2212 | ) | |
2213 | ||
5f4c791e | 2214 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,18,0)) |
51ab0b1d MJ |
2215 | |
2216 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, | |
2217 | ||
2218 | TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, | |
2219 | u64 len), | |
2220 | ||
2221 | TP_ARGS(block_group, start, len), | |
2222 | ||
2223 | TP_FIELDS( | |
9d2f1147 | 2224 | ctf_array(u8, fsid, block_group->lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
51ab0b1d MJ |
2225 | ctf_integer(u64, bg_objectid, block_group->key.objectid) |
2226 | ctf_integer(u64, flags, block_group->flags) | |
2227 | ctf_integer(u64, start, start) | |
2228 | ctf_integer(u64, len, len) | |
2229 | ) | |
2230 | ) | |
2231 | ||
2232 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2233 | ||
2234 | TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, | |
2235 | u64 len), | |
2236 | ||
2237 | TP_ARGS(block_group, start, len) | |
2238 | ) | |
2239 | ||
2240 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2241 | ||
2242 | TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, | |
2243 | u64 len), | |
2244 | ||
2245 | TP_ARGS(block_group, start, len) | |
2246 | ) | |
ff8bdcc2 | 2247 | |
5f4c791e | 2248 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0)) |
1f1ec4ed MJ |
2249 | |
2250 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, | |
2251 | ||
9d2f1147 | 2252 | TP_PROTO(const struct btrfs_fs_info *fs_info, |
1f1ec4ed MJ |
2253 | const struct btrfs_block_group_cache *block_group, u64 start, |
2254 | u64 len), | |
2255 | ||
9d2f1147 | 2256 | TP_ARGS(fs_info, block_group, start, len), |
1f1ec4ed MJ |
2257 | |
2258 | TP_FIELDS( | |
9d2f1147 | 2259 | ctf_array(u8, fsid, lttng_fs_info_fsid, BTRFS_UUID_SIZE) |
1f1ec4ed MJ |
2260 | ctf_integer(u64, bg_objectid, block_group->key.objectid) |
2261 | ctf_integer(u64, flags, block_group->flags) | |
2262 | ctf_integer(u64, start, start) | |
2263 | ctf_integer(u64, len, len) | |
2264 | ) | |
2265 | ) | |
2266 | ||
2267 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2268 | ||
9d2f1147 | 2269 | TP_PROTO(const struct btrfs_fs_info *fs_info, |
1f1ec4ed MJ |
2270 | const struct btrfs_block_group_cache *block_group, u64 start, |
2271 | u64 len), | |
2272 | ||
9d2f1147 | 2273 | TP_ARGS(fs_info, block_group, start, len) |
1f1ec4ed MJ |
2274 | ) |
2275 | ||
2276 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2277 | ||
9d2f1147 | 2278 | TP_PROTO(const struct btrfs_fs_info *fs_info, |
1f1ec4ed MJ |
2279 | const struct btrfs_block_group_cache *block_group, u64 start, |
2280 | u64 len), | |
2281 | ||
9d2f1147 | 2282 | TP_ARGS(fs_info, block_group, start, len) |
1f1ec4ed MJ |
2283 | ) |
2284 | ||
5f4c791e | 2285 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) |
1f1ec4ed | 2286 | |
ff8bdcc2 MD |
2287 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, |
2288 | ||
9d2f1147 | 2289 | TP_PROTO(struct btrfs_fs_info *fs_info, |
ff8bdcc2 MD |
2290 | struct btrfs_block_group_cache *block_group, u64 start, |
2291 | u64 len), | |
2292 | ||
9d2f1147 | 2293 | TP_ARGS(fs_info, block_group, start, len), |
ff8bdcc2 MD |
2294 | |
2295 | TP_FIELDS( | |
2296 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2297 | ctf_integer(u64, flags, block_group->flags) | |
2298 | ctf_integer(u64, start, start) | |
2299 | ctf_integer(u64, len, len) | |
2300 | ) | |
2301 | ) | |
2302 | ||
2303 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2304 | ||
9d2f1147 | 2305 | TP_PROTO(struct btrfs_fs_info *fs_info, |
ff8bdcc2 MD |
2306 | struct btrfs_block_group_cache *block_group, u64 start, |
2307 | u64 len), | |
2308 | ||
9d2f1147 | 2309 | TP_ARGS(fs_info, block_group, start, len) |
ff8bdcc2 MD |
2310 | ) |
2311 | ||
2312 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2313 | ||
9d2f1147 | 2314 | TP_PROTO(struct btrfs_fs_info *fs_info, |
ff8bdcc2 MD |
2315 | struct btrfs_block_group_cache *block_group, u64 start, |
2316 | u64 len), | |
2317 | ||
9d2f1147 | 2318 | TP_ARGS(fs_info, block_group, start, len) |
ff8bdcc2 | 2319 | ) |
0badc02f MJ |
2320 | #elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
2321 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
2322 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
2323 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) | |
7ca7cd6e | 2324 | |
7ca7cd6e MJ |
2325 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, |
2326 | ||
2327 | TP_PROTO(const struct btrfs_root *root, | |
2328 | const struct btrfs_block_group_cache *block_group, u64 start, | |
2329 | u64 len), | |
2330 | ||
2331 | TP_ARGS(root, block_group, start, len), | |
2332 | ||
2333 | TP_FIELDS( | |
2334 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2335 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2336 | ctf_integer(u64, flags, block_group->flags) | |
2337 | ctf_integer(u64, start, start) | |
2338 | ctf_integer(u64, len, len) | |
2339 | ) | |
2340 | ) | |
2341 | ||
2342 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, | |
2343 | ||
2344 | TP_PROTO(const struct btrfs_root *root, | |
2345 | const struct btrfs_block_group_cache *block_group, u64 start, | |
2346 | u64 len), | |
2347 | ||
2348 | TP_ARGS(root, block_group, start, len) | |
2349 | ) | |
2350 | ||
2351 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, | |
2352 | ||
2353 | TP_PROTO(const struct btrfs_root *root, | |
2354 | const struct btrfs_block_group_cache *block_group, u64 start, | |
2355 | u64 len), | |
2356 | ||
2357 | TP_ARGS(root, block_group, start, len) | |
2358 | ) | |
ff8bdcc2 | 2359 | |
3b67cf3e | 2360 | #else |
ff8bdcc2 | 2361 | |
3bc29f0a | 2362 | LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, |
b87700e3 AG |
2363 | |
2364 | TP_PROTO(struct btrfs_root *root, | |
2365 | struct btrfs_block_group_cache *block_group, u64 start, | |
2366 | u64 len), | |
2367 | ||
2368 | TP_ARGS(root, block_group, start, len), | |
2369 | ||
f127e61e MD |
2370 | TP_FIELDS( |
2371 | ctf_integer(u64, root_objectid, root->root_key.objectid) | |
2372 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2373 | ctf_integer(u64, flags, block_group->flags) | |
2374 | ctf_integer(u64, start, start) | |
2375 | ctf_integer(u64, len, len) | |
2376 | ) | |
b87700e3 AG |
2377 | ) |
2378 | ||
3bc29f0a | 2379 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, |
b87700e3 AG |
2380 | |
2381 | TP_PROTO(struct btrfs_root *root, | |
2382 | struct btrfs_block_group_cache *block_group, u64 start, | |
2383 | u64 len), | |
2384 | ||
2385 | TP_ARGS(root, block_group, start, len) | |
2386 | ) | |
2387 | ||
3bc29f0a | 2388 | LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, |
b87700e3 AG |
2389 | |
2390 | TP_PROTO(struct btrfs_root *root, | |
2391 | struct btrfs_block_group_cache *block_group, u64 start, | |
2392 | u64 len), | |
2393 | ||
2394 | TP_ARGS(root, block_group, start, len) | |
2395 | ) | |
2396 | ||
5f4c791e | 2397 | #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,10,0)) */ |
ff8bdcc2 | 2398 | |
5f4c791e | 2399 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,5,0)) |
5809d816 MJ |
2400 | LTTNG_TRACEPOINT_EVENT(btrfs_find_cluster, |
2401 | ||
2402 | TP_PROTO(const struct btrfs_block_group *block_group, u64 start, | |
2403 | u64 bytes, u64 empty_size, u64 min_bytes), | |
2404 | ||
2405 | TP_ARGS(block_group, start, bytes, empty_size, min_bytes), | |
2406 | ||
2407 | TP_FIELDS( | |
2408 | ctf_integer(u64, bg_objectid, block_group->start) | |
2409 | ctf_integer(u64, flags, block_group->flags) | |
2410 | ctf_integer(u64, start, start) | |
2411 | ctf_integer(u64, bytes, bytes) | |
2412 | ctf_integer(u64, empty_size, empty_size) | |
2413 | ctf_integer(u64, min_bytes, min_bytes) | |
2414 | ) | |
2415 | ) | |
2416 | ||
2417 | LTTNG_TRACEPOINT_EVENT(btrfs_failed_cluster_setup, | |
2418 | ||
2419 | TP_PROTO(const struct btrfs_block_group *block_group), | |
2420 | ||
2421 | TP_ARGS(block_group), | |
2422 | ||
2423 | TP_FIELDS( | |
2424 | ctf_integer(u64, bg_objectid, block_group->start) | |
2425 | ) | |
2426 | ) | |
2427 | ||
2428 | LTTNG_TRACEPOINT_EVENT(btrfs_setup_cluster, | |
2429 | ||
2430 | TP_PROTO(const struct btrfs_block_group *block_group, | |
2431 | const struct btrfs_free_cluster *cluster, u64 size, int bitmap), | |
2432 | ||
2433 | TP_ARGS(block_group, cluster, size, bitmap), | |
2434 | ||
2435 | TP_FIELDS( | |
2436 | ctf_integer(u64, bg_objectid, block_group->start) | |
2437 | ctf_integer(u64, flags, block_group->flags) | |
2438 | ctf_integer(u64, start, cluster->window_start) | |
2439 | ctf_integer(u64, max_size, cluster->max_size) | |
2440 | ctf_integer(u64, size, size) | |
2441 | ctf_integer(int, bitmap, bitmap) | |
2442 | ) | |
2443 | ) | |
5f4c791e | 2444 | #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
2445 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
2446 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
2447 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 2448 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
2449 | LTTNG_TRACEPOINT_EVENT(btrfs_find_cluster, |
2450 | ||
2451 | TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, | |
2452 | u64 bytes, u64 empty_size, u64 min_bytes), | |
2453 | ||
2454 | TP_ARGS(block_group, start, bytes, empty_size, min_bytes), | |
2455 | ||
2456 | TP_FIELDS( | |
2457 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2458 | ctf_integer(u64, flags, block_group->flags) | |
2459 | ctf_integer(u64, start, start) | |
2460 | ctf_integer(u64, bytes, bytes) | |
2461 | ctf_integer(u64, empty_size, empty_size) | |
2462 | ctf_integer(u64, min_bytes, min_bytes) | |
2463 | ) | |
2464 | ) | |
2465 | ||
2466 | LTTNG_TRACEPOINT_EVENT(btrfs_failed_cluster_setup, | |
2467 | ||
2468 | TP_PROTO(const struct btrfs_block_group_cache *block_group), | |
2469 | ||
2470 | TP_ARGS(block_group), | |
2471 | ||
2472 | TP_FIELDS( | |
2473 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2474 | ) | |
2475 | ) | |
2476 | ||
2477 | LTTNG_TRACEPOINT_EVENT(btrfs_setup_cluster, | |
2478 | ||
2479 | TP_PROTO(const struct btrfs_block_group_cache *block_group, | |
2480 | const struct btrfs_free_cluster *cluster, u64 size, int bitmap), | |
2481 | ||
2482 | TP_ARGS(block_group, cluster, size, bitmap), | |
2483 | ||
2484 | TP_FIELDS( | |
2485 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2486 | ctf_integer(u64, flags, block_group->flags) | |
2487 | ctf_integer(u64, start, cluster->window_start) | |
2488 | ctf_integer(u64, max_size, cluster->max_size) | |
2489 | ctf_integer(u64, size, size) | |
2490 | ctf_integer(int, bitmap, bitmap) | |
2491 | ) | |
2492 | ) | |
3b67cf3e | 2493 | #else |
3bc29f0a | 2494 | LTTNG_TRACEPOINT_EVENT(btrfs_find_cluster, |
b87700e3 AG |
2495 | |
2496 | TP_PROTO(struct btrfs_block_group_cache *block_group, u64 start, | |
2497 | u64 bytes, u64 empty_size, u64 min_bytes), | |
2498 | ||
2499 | TP_ARGS(block_group, start, bytes, empty_size, min_bytes), | |
2500 | ||
f127e61e MD |
2501 | TP_FIELDS( |
2502 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2503 | ctf_integer(u64, flags, block_group->flags) | |
2504 | ctf_integer(u64, start, start) | |
2505 | ctf_integer(u64, bytes, bytes) | |
2506 | ctf_integer(u64, empty_size, empty_size) | |
2507 | ctf_integer(u64, min_bytes, min_bytes) | |
2508 | ) | |
b87700e3 AG |
2509 | ) |
2510 | ||
3bc29f0a | 2511 | LTTNG_TRACEPOINT_EVENT(btrfs_failed_cluster_setup, |
b87700e3 AG |
2512 | |
2513 | TP_PROTO(struct btrfs_block_group_cache *block_group), | |
2514 | ||
2515 | TP_ARGS(block_group), | |
2516 | ||
f127e61e MD |
2517 | TP_FIELDS( |
2518 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2519 | ) | |
b87700e3 AG |
2520 | ) |
2521 | ||
3bc29f0a | 2522 | LTTNG_TRACEPOINT_EVENT(btrfs_setup_cluster, |
b87700e3 AG |
2523 | |
2524 | TP_PROTO(struct btrfs_block_group_cache *block_group, | |
2525 | struct btrfs_free_cluster *cluster, u64 size, int bitmap), | |
2526 | ||
2527 | TP_ARGS(block_group, cluster, size, bitmap), | |
2528 | ||
f127e61e MD |
2529 | TP_FIELDS( |
2530 | ctf_integer(u64, bg_objectid, block_group->key.objectid) | |
2531 | ctf_integer(u64, flags, block_group->flags) | |
2532 | ctf_integer(u64, start, cluster->window_start) | |
2533 | ctf_integer(u64, max_size, cluster->max_size) | |
2534 | ctf_integer(u64, size, size) | |
2535 | ctf_integer(int, bitmap, bitmap) | |
2536 | ) | |
b87700e3 AG |
2537 | ) |
2538 | #endif | |
2539 | ||
5f4c791e | 2540 | #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,14,0) || \ |
0badc02f MJ |
2541 | LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ |
2542 | LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ | |
2543 | LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ | |
7ca7cd6e | 2544 | LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) |
1f1ec4ed MJ |
2545 | LTTNG_TRACEPOINT_EVENT_MAP(alloc_extent_state, |
2546 | ||
2547 | btrfs_alloc_extent_state, | |
2548 | ||
2549 | TP_PROTO(const struct extent_state *state, gfp_t mask, unsigned long IP), | |
2550 | ||
2551 | TP_ARGS(state, mask, IP), | |
2552 | ||
2553 | TP_FIELDS( | |
2554 | ctf_integer_hex(const struct extent_state *, state, state) | |
2555 | ctf_integer(gfp_t, mask, mask) | |
2c054599 | 2556 | ctf_integer_hex(unsigned long, ip, IP) |
1f1ec4ed MJ |
2557 | ) |
2558 | ) | |
2559 | ||
2560 | LTTNG_TRACEPOINT_EVENT_MAP(free_extent_state, | |
2561 | ||
2562 | btrfs_free_extent_state, | |
2563 | ||
2564 | TP_PROTO(const struct extent_state *state, unsigned long IP), | |
2565 | ||
2566 | TP_ARGS(state, IP), | |
2567 | ||
2568 | TP_FIELDS( | |
2569 | ctf_integer_hex(const struct extent_state *, state, state) | |
2c054599 | 2570 | ctf_integer_hex(unsigned long, ip, IP) |
1f1ec4ed MJ |
2571 | ) |
2572 | ) | |
3b67cf3e | 2573 | #else |
3bc29f0a | 2574 | LTTNG_TRACEPOINT_EVENT_MAP(alloc_extent_state, |
9cf29d3e MD |
2575 | |
2576 | btrfs_alloc_extent_state, | |
b87700e3 AG |
2577 | |
2578 | TP_PROTO(struct extent_state *state, gfp_t mask, unsigned long IP), | |
2579 | ||
2580 | TP_ARGS(state, mask, IP), | |
2581 | ||
f127e61e | 2582 | TP_FIELDS( |
fa91fcac | 2583 | ctf_integer_hex(struct extent_state *, state, state) |
f127e61e | 2584 | ctf_integer(gfp_t, mask, mask) |
2c054599 | 2585 | ctf_integer_hex(unsigned long, ip, IP) |
f127e61e | 2586 | ) |
b87700e3 AG |
2587 | ) |
2588 | ||
3bc29f0a | 2589 | LTTNG_TRACEPOINT_EVENT_MAP(free_extent_state, |
9cf29d3e MD |
2590 | |
2591 | btrfs_free_extent_state, | |
b87700e3 AG |
2592 | |
2593 | TP_PROTO(struct extent_state *state, unsigned long IP), | |
2594 | ||
2595 | TP_ARGS(state, IP), | |
2596 | ||
f127e61e | 2597 | TP_FIELDS( |
fa91fcac | 2598 | ctf_integer_hex(struct extent_state *, state, state) |
2c054599 | 2599 | ctf_integer_hex(unsigned long, ip, IP) |
f127e61e | 2600 | ) |
b87700e3 AG |
2601 | ) |
2602 | #endif | |
2603 | ||
3bc29f0a | 2604 | #endif /* LTTNG_TRACE_BTRFS_H */ |
b87700e3 AG |
2605 | |
2606 | /* This part must be outside protection */ | |
3b4aafcb | 2607 | #include <lttng/define_trace.h> |