X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=instrumentation%2Fevents%2Flttng-module%2Fbtrfs.h;h=4dfbf5b329e45a4c5fe9133ca6a2b46a3ade7a48;hb=818760e10c149acab72fe73be7efd5fd0e822463;hp=b3bf72c1c3d881d370d9df4beebcada586b4c4bf;hpb=b837df2cce5bc9272b8766d325144a8c77ea8281;p=lttng-modules.git diff --git a/instrumentation/events/lttng-module/btrfs.h b/instrumentation/events/lttng-module/btrfs.h index b3bf72c1..4dfbf5b3 100644 --- a/instrumentation/events/lttng-module/btrfs.h +++ b/instrumentation/events/lttng-module/btrfs.h @@ -33,6 +33,9 @@ struct extent_state; #define BTRFS_UUID_SIZE 16 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_transaction_commit, @@ -229,7 +232,10 @@ LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, ) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_get_extent, @@ -316,7 +322,10 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, BTRFS_I(inode)->root->root_key.objectid) ) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, TP_PROTO(const struct inode *inode, const struct btrfs_ordered_extent *ordered), @@ -361,6 +370,9 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__ordered_extent, #endif #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__ordered_extent, btrfs_ordered_extent_add, @@ -563,7 +575,13 @@ LTTNG_TRACEPOINT_EVENT(btrfs_sync_file, #endif #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ - LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,114,92,0,0)) + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_sync_fs, TP_PROTO(const struct btrfs_fs_info *fs_info, int wait), @@ -599,6 +617,9 @@ LTTNG_TRACEPOINT_EVENT(btrfs_sync_fs, #endif #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_add_block_group, @@ -743,7 +764,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, ) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + add_delayed_ref_head, + + btrfs_add_delayed_ref_head, TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_delayed_ref_head *head_ref, @@ -752,7 +777,11 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, TP_ARGS(fs_info, head_ref, action) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + run_delayed_ref_head, + + btrfs_run_delayed_ref_head, TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_delayed_ref_head *head_ref, @@ -762,7 +791,14 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, ) #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ - LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,114,92,0,0)) + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,4,103,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,114,94,0,0, 4,4,114,95,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,120,94,0,0, 4,4,120,95,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,126,94,0,0, 4,5,0,0,0,0)) + LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, TP_PROTO(const struct btrfs_fs_info *fs_info, @@ -780,7 +816,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, ) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + add_delayed_ref_head, + + btrfs_add_delayed_ref_head, TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_delayed_ref_node *ref, @@ -790,7 +830,11 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, TP_ARGS(fs_info, ref, head_ref, action) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + run_delayed_ref_head, + + btrfs_run_delayed_ref_head, TP_PROTO(const struct btrfs_fs_info *fs_info, const struct btrfs_delayed_ref_node *ref, @@ -818,7 +862,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, ) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + add_delayed_ref_head, + + btrfs_add_delayed_ref_head, TP_PROTO(struct btrfs_fs_info *fs_info, struct btrfs_delayed_ref_node *ref, @@ -828,7 +876,11 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, TP_ARGS(fs_info, ref, head_ref, action) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + run_delayed_ref_head, + + btrfs_run_delayed_ref_head, TP_PROTO(struct btrfs_fs_info *fs_info, struct btrfs_delayed_ref_node *ref, @@ -838,7 +890,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, TP_ARGS(fs_info, ref, head_ref, action) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,114,92,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,92,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, TP_PROTO(const struct btrfs_delayed_ref_node *ref, @@ -855,7 +907,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, ) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + add_delayed_ref_head, + + btrfs_add_delayed_ref_head, TP_PROTO(const struct btrfs_delayed_ref_node *ref, const struct btrfs_delayed_ref_head *head_ref, @@ -864,7 +920,11 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, TP_ARGS(ref, head_ref, action) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + run_delayed_ref_head, + + btrfs_run_delayed_ref_head, TP_PROTO(const struct btrfs_delayed_ref_node *ref, const struct btrfs_delayed_ref_head *head_ref, @@ -890,7 +950,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs_delayed_ref_head, ) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + add_delayed_ref_head, + + btrfs_add_delayed_ref_head, TP_PROTO(struct btrfs_delayed_ref_node *ref, struct btrfs_delayed_ref_head *head_ref, @@ -899,7 +963,11 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, add_delayed_ref_head, TP_ARGS(ref, head_ref, action) ) -LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs_delayed_ref_head, run_delayed_ref_head, +LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(btrfs_delayed_ref_head, + + run_delayed_ref_head, + + btrfs_run_delayed_ref_head, TP_PROTO(struct btrfs_delayed_ref_node *ref, struct btrfs_delayed_ref_head *head_ref, @@ -996,7 +1064,10 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, TP_ARGS(info, map, offset, size) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__chunk, @@ -1069,6 +1140,9 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__chunk, btrfs_chunk_free, #endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)) */ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_cow_block, @@ -1106,6 +1180,9 @@ LTTNG_TRACEPOINT_EVENT(btrfs_cow_block, #endif #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_space_reservation, @@ -1196,7 +1273,10 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_f TP_ARGS(info, start, len) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserved_extent, @@ -1256,8 +1336,57 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_f #endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)) */ -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0)) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,18,0)) +LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, + + btrfs_find_free_extent, + + TP_PROTO(const struct btrfs_fs_info *info, u64 num_bytes, u64 empty_size, + u64 data), + + TP_ARGS(info, num_bytes, empty_size, data), + + TP_FIELDS( + ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE) + ctf_integer(u64, num_bytes, num_bytes) + ctf_integer(u64, empty_size, empty_size) + ctf_integer(u64, data, data) + ) +) + +LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, + + TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, + u64 len), + + TP_ARGS(block_group, start, len), + TP_FIELDS( + ctf_array(u8, fsid, block_group->fs_info->fsid, BTRFS_UUID_SIZE) + ctf_integer(u64, bg_objectid, block_group->key.objectid) + ctf_integer(u64, flags, block_group->flags) + ctf_integer(u64, start, start) + ctf_integer(u64, len, len) + ) +) + +LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent, + + TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, + u64 len), + + TP_ARGS(block_group, start, len) +) + +LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster, + + TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start, + u64 len), + + TP_ARGS(block_group, start, len) +) + +#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0)) LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, btrfs_find_free_extent, @@ -1268,6 +1397,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, TP_ARGS(info, num_bytes, empty_size, data), TP_FIELDS( + ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE) ctf_integer(u64, num_bytes, num_bytes) ctf_integer(u64, empty_size, empty_size) ctf_integer(u64, data, data) @@ -1283,6 +1413,7 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent, TP_ARGS(info, block_group, start, len), TP_FIELDS( + ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE) ctf_integer(u64, bg_objectid, block_group->key.objectid) ctf_integer(u64, flags, block_group->flags) ctf_integer(u64, start, start) @@ -1320,6 +1451,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, TP_ARGS(info, num_bytes, empty_size, data), TP_FIELDS( + ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE) ctf_integer(u64, num_bytes, num_bytes) ctf_integer(u64, empty_size, empty_size) ctf_integer(u64, data, data) @@ -1359,7 +1491,10 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_clus TP_ARGS(info, block_group, start, len) ) -#elif (LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) +#elif (LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent, @@ -1470,6 +1605,9 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_clus #endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)) */ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(btrfs_find_cluster, @@ -1563,6 +1701,9 @@ LTTNG_TRACEPOINT_EVENT(btrfs_setup_cluster, #endif #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,73,5,0,0, 4,4,73,6,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,82,6,0,0, 4,4,82,7,0,0) || \ + LTTNG_SLE_KERNEL_RANGE(4,4,92,6,0,0, 4,4,92,7,0,0) || \ LTTNG_SLE_KERNEL_RANGE(4,4,103,6,0,0, 4,5,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_MAP(alloc_extent_state,