btrfs-progs: print-tree: rename item callbacks to match the key name

Signed-off-by: David Sterba <dsterba@suse.com>
master
David Sterba 2017-08-31 16:34:15 +02:00
parent b3d343fc9c
commit 1224f7343e
3 changed files with 6 additions and 6 deletions

View File

@ -118,7 +118,7 @@ static void print_sys_chunk_array(struct btrfs_super_block *sb)
len = btrfs_chunk_item_size(num_stripes);
if (cur_offset + len > array_size)
goto out_short_read;
print_chunk(buf, chunk);
print_chunk_item(buf, chunk);
} else {
error("unexpected item type %u in sys_array at offset %u",
(u32)key.type, cur_offset);

View File

@ -195,7 +195,7 @@ static void qgroup_flags_to_str(u64 flags, char *ret)
strcat(ret, "|INCONSISTENT");
}
void print_chunk(struct extent_buffer *eb, struct btrfs_chunk *chunk)
void print_chunk_item(struct extent_buffer *eb, struct btrfs_chunk *chunk)
{
u16 num_stripes = btrfs_chunk_num_stripes(eb, chunk);
int i;
@ -541,7 +541,7 @@ static void root_flags_to_str(u64 flags, char *ret)
strcat(ret, "none");
}
static void print_root(struct extent_buffer *leaf, int slot)
static void print_root_item(struct extent_buffer *leaf, int slot)
{
struct btrfs_root_item *ri;
struct btrfs_root_item root_item;
@ -1054,7 +1054,7 @@ void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *eb)
printf("\t\torphan item\n");
break;
case BTRFS_ROOT_ITEM_KEY:
print_root(eb, i);
print_root_item(eb, i);
break;
case BTRFS_ROOT_REF_KEY:
print_root_ref(eb, i, "ref");
@ -1139,7 +1139,7 @@ void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *eb)
printf("\t\tfree space bitmap\n");
break;
case BTRFS_CHUNK_ITEM_KEY:
print_chunk(eb, ptr);
print_chunk_item(eb, ptr);
break;
case BTRFS_DEV_ITEM_KEY:
print_dev_item(eb, ptr);

View File

@ -22,7 +22,7 @@
void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *l);
void btrfs_print_tree(struct btrfs_root *root, struct extent_buffer *t, int follow);
void btrfs_print_key(struct btrfs_disk_key *disk_key);
void print_chunk(struct extent_buffer *eb, struct btrfs_chunk *chunk);
void print_chunk_item(struct extent_buffer *eb, struct btrfs_chunk *chunk);
void print_extent_item(struct extent_buffer *eb, int slot, int metadata);
void print_objectid(FILE *stream, u64 objectid, u8 type);
void print_key_type(FILE *stream, u64 objectid, u8 type);