Skip to content

Commit

Permalink
Btrfs: fix wrong parse of extent map's tracepoint
Browse files Browse the repository at this point in the history
The tracepoint of extent map doesn't parse @flag correctly, we set @flag via
set_bit(), so we need to parse it on a bit bias.

Also add the missing flag, EXTENT_FLAG_FS_MAPPING.

Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
Signed-off-by: Chris Mason <clm@fb.com>
  • Loading branch information
Liu Bo authored and Chris Mason committed Sep 18, 2014
1 parent e6c4efd commit 254a2d1
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions include/trace/events/btrfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,13 @@ DEFINE_EVENT(btrfs__inode, btrfs_inode_evict,

#define show_map_flags(flag) \
__print_flags(flag, "|", \
{ EXTENT_FLAG_PINNED, "PINNED" }, \
{ EXTENT_FLAG_COMPRESSED, "COMPRESSED" }, \
{ EXTENT_FLAG_VACANCY, "VACANCY" }, \
{ EXTENT_FLAG_PREALLOC, "PREALLOC" }, \
{ EXTENT_FLAG_LOGGING, "LOGGING" }, \
{ EXTENT_FLAG_FILLING, "FILLING" })
{ (1 << EXTENT_FLAG_PINNED), "PINNED" },\
{ (1 << EXTENT_FLAG_COMPRESSED), "COMPRESSED" },\
{ (1 << EXTENT_FLAG_VACANCY), "VACANCY" },\
{ (1 << EXTENT_FLAG_PREALLOC), "PREALLOC" },\
{ (1 << EXTENT_FLAG_LOGGING), "LOGGING" },\
{ (1 << EXTENT_FLAG_FILLING), "FILLING" },\
{ (1 << EXTENT_FLAG_FS_MAPPING), "FS_MAPPING" })

TRACE_EVENT_CONDITION(btrfs_get_extent,

Expand Down

0 comments on commit 254a2d1

Please sign in to comment.