btrfs-progs: print-tree: add BTRFS_DEV_ITEMS_OBJECTID in comment

So when searching for BTRFS_DEV_ITEMS_OBJECTID, it hits, albeit it is
defined same as BTRFS_ROOT_TREE_OBJECTID.

Reviewed-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
master
Anand Jain 2019-08-28 22:06:05 +08:00 committed by David Sterba
parent f41f929854
commit 95c49ef7f7
1 changed files with 5 additions and 0 deletions

View File

@ -711,6 +711,11 @@ void print_objectid(FILE *stream, u64 objectid, u8 type)
switch (objectid) {
case BTRFS_ROOT_TREE_OBJECTID:
/*
* BTRFS_ROOT_TREE_OBJECTID and BTRFS_DEV_ITEMS_OBJECTID are
* defined with the same value 1, we need to distinguish them
* by the type.
*/
if (type == BTRFS_DEV_ITEM_KEY)
fprintf(stream, "DEV_ITEMS");
else