btrfs: tracepoints: fix qgroup reservation type printing
authorNikolay Borisov <nborisov@suse.com>
Fri, 19 Jun 2020 12:24:49 +0000 (15:24 +0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 27 Jul 2020 10:55:29 +0000 (12:55 +0200)
commit1cb1f0b2486b0893a3ebf20c42f2df27649ae2b4
tree1b4151559fcf37a3d2d340a0f68e3f67867d6489
parent5bca2c952c609b128b00a238fadb99cc0d3b65ab
btrfs: tracepoints: fix qgroup reservation type printing

Since qgroup's reservation types are define in a macro they must be
exported to user space in order for user space tools to convert raw
binary data to symbolic names. Currently trace-cmd report produces
the following output:

kworker/u8:2-459   [003]  1208.543587: qgroup_update_reserve:
2b742cae-e0e5-4def-9ef7-28a9b34a951e: qgid=5 type=0x2 cur_reserved=54870016 diff=-32768

With this fix the output is:

kworker/u8:2-459   [003]  1208.543587: qgroup_update_reserve:
2b742cae-e0e5-4def-9ef7-28a9b34a951e: qgid=5 type=BTRFS_QGROUP_RSV_META_PREALLOC cur_reserved=54870016 diff=-32768

Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
include/trace/events/btrfs.h