diff options
author | Lakshmipathi.G <Lakshmipathi.G@giis.co.in> | 2015-10-07 17:36:38 +0530 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2015-11-02 09:35:00 +0100 |
commit | 86f61d3bb334d05274d4635c35e3a173eccf0062 (patch) | |
tree | 74a34d2a11c34d94f5872582e81b02ed46eecaee /print-tree.c | |
parent | 4ee3d2e94d4d593ab850c661dc3d7036b3cc2c98 (diff) |
btrfs-progs: print root item's last_snapshot value
Include last_snapshot value in print_root(). With btrfs-debug-tree, it
helps to identify whether its a snapshot-ed subvolume or not.
Signed-off-by: Lakshmipathi.G <Lakshmipathi.G@giis.co.in>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'print-tree.c')
-rw-r--r-- | print-tree.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/print-tree.c b/print-tree.c index dc1d2764..7ddf400d 100644 --- a/print-tree.c +++ b/print-tree.c @@ -481,12 +481,13 @@ static void print_root(struct extent_buffer *leaf, int slot) memset(&root_item, 0, sizeof(root_item)); read_extent_buffer(leaf, &root_item, (unsigned long)ri, len); - printf("\t\troot data bytenr %llu level %d dirid %llu refs %u gen %llu\n", + printf("\t\troot data bytenr %llu level %d dirid %llu refs %u gen %llu lastsnap %llu\n", (unsigned long long)btrfs_root_bytenr(&root_item), btrfs_root_level(&root_item), (unsigned long long)btrfs_root_dirid(&root_item), btrfs_root_refs(&root_item), - (unsigned long long)btrfs_root_generation(&root_item)); + (unsigned long long)btrfs_root_generation(&root_item), + (unsigned long long)btrfs_root_last_snapshot(&root_item)); if (root_item.generation == root_item.generation_v2) { uuid_unparse(root_item.uuid, uuid_str); |