Btrfs: Add inode map, and the start of file extent items
[linux-2.6-block.git] / fs / btrfs / debug-tree.c
CommitLineData
fec577fb
CM
1#include <stdio.h>
2#include <stdlib.h>
3#include "kerncompat.h"
4#include "radix-tree.h"
5#include "ctree.h"
6#include "disk-io.h"
7#include "print-tree.h"
e089f05c 8#include "transaction.h"
fec577fb 9
af86d07e 10int main(int ac, char **av) {
234b63a0
CM
11 struct btrfs_super_block super;
12 struct btrfs_root *root;
fec577fb
CM
13 radix_tree_init();
14 root = open_ctree("dbfile", &super);
3768f368 15 printf("fs tree\n");
234b63a0 16 btrfs_print_tree(root, root->node);
fec577fb 17 printf("map tree\n");
9f5fae2f
CM
18 btrfs_print_tree(root->fs_info->extent_root,
19 root->fs_info->extent_root->node);
20 printf("inode tree\n");
21 btrfs_print_tree(root->fs_info->inode_root,
22 root->fs_info->inode_root->node);
3768f368 23 printf("root tree\n");
9f5fae2f
CM
24 btrfs_print_tree(root->fs_info->tree_root,
25 root->fs_info->tree_root->node);
fec577fb
CM
26 return 0;
27}