btrfs: tracepoints: output proper root owner for trace_find_free_extent()
[sfrench/cifs-2.6.git] / include / trace / events / btrfs.h
index 863335ecb7e8a3e891d7e34472c6292eb164ce0f..b9241836d4f73eaa7d4fbd3c427dac4f0cb2cb4b 100644 (file)
@@ -1176,25 +1176,27 @@ DEFINE_EVENT(btrfs__reserved_extent,  btrfs_reserved_extent_free,
 
 TRACE_EVENT(find_free_extent,
 
-       TP_PROTO(const struct btrfs_fs_info *fs_info, u64 num_bytes,
+       TP_PROTO(const struct btrfs_root *root, u64 num_bytes,
                 u64 empty_size, u64 data),
 
-       TP_ARGS(fs_info, num_bytes, empty_size, data),
+       TP_ARGS(root, num_bytes, empty_size, data),
 
        TP_STRUCT__entry_btrfs(
+               __field(        u64,    root_objectid           )
                __field(        u64,    num_bytes               )
                __field(        u64,    empty_size              )
                __field(        u64,    data                    )
        ),
 
-       TP_fast_assign_btrfs(fs_info,
+       TP_fast_assign_btrfs(root->fs_info,
+               __entry->root_objectid  = root->root_key.objectid;
                __entry->num_bytes      = num_bytes;
                __entry->empty_size     = empty_size;
                __entry->data           = data;
        ),
 
        TP_printk_btrfs("root=%llu(%s) len=%llu empty_size=%llu flags=%llu(%s)",
-                 show_root_type(BTRFS_EXTENT_TREE_OBJECTID),
+                 show_root_type(__entry->root_objectid),
                  __entry->num_bytes, __entry->empty_size, __entry->data,
                  __print_flags((unsigned long)__entry->data, "|",
                                 BTRFS_GROUP_FLAGS))