diff options
author | Chris Mason <chris.mason@oracle.com> | 2007-12-11 09:25:06 -0500 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2008-09-25 11:03:58 -0400 |
commit | 7bb86316c3961d1bc401ef184fd996f999556c7f (patch) | |
tree | e67de3b594cf680f295010095a71ed7e825cb757 /fs/btrfs/print-tree.c | |
parent | 74493f7a59bfd4d1c7029c74ab2cd0e400612c6b (diff) |
Btrfs: Add back pointers from extents to the btree or file referencing them
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/print-tree.c')
-rw-r--r-- | fs/btrfs/print-tree.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/fs/btrfs/print-tree.c b/fs/btrfs/print-tree.c index 030324febf6c..da0b4dcf3617 100644 --- a/fs/btrfs/print-tree.c +++ b/fs/btrfs/print-tree.c | |||
@@ -33,6 +33,7 @@ void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *l) | |||
33 | struct btrfs_file_extent_item *fi; | 33 | struct btrfs_file_extent_item *fi; |
34 | struct btrfs_key key; | 34 | struct btrfs_key key; |
35 | struct btrfs_key found_key; | 35 | struct btrfs_key found_key; |
36 | struct btrfs_extent_ref *ref; | ||
36 | u32 type; | 37 | u32 type; |
37 | 38 | ||
38 | printk("leaf %llu total ptrs %d free space %d\n", | 39 | printk("leaf %llu total ptrs %d free space %d\n", |
@@ -73,6 +74,15 @@ void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *l) | |||
73 | printk("\t\textent data refs %u\n", | 74 | printk("\t\textent data refs %u\n", |
74 | btrfs_extent_refs(l, ei)); | 75 | btrfs_extent_refs(l, ei)); |
75 | break; | 76 | break; |
77 | case BTRFS_EXTENT_REF_KEY: | ||
78 | ref = btrfs_item_ptr(l, i, struct btrfs_extent_ref); | ||
79 | printk("\t\textent back ref root %llu gen %llu " | ||
80 | "owner %llu offset %llu\n", | ||
81 | (unsigned long long)btrfs_ref_root(l, ref), | ||
82 | (unsigned long long)btrfs_ref_generation(l, ref), | ||
83 | (unsigned long long)btrfs_ref_objectid(l, ref), | ||
84 | (unsigned long long)btrfs_ref_offset(l, ref)); | ||
85 | break; | ||
76 | 86 | ||
77 | case BTRFS_EXTENT_DATA_KEY: | 87 | case BTRFS_EXTENT_DATA_KEY: |
78 | fi = btrfs_item_ptr(l, i, | 88 | fi = btrfs_item_ptr(l, i, |