diff options
author | Chris Mason <chris.mason@oracle.com> | 2012-02-21 14:37:21 -0500 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2012-02-21 14:37:21 -0500 |
commit | af00db292e74b22c51cd95f1db5db2a594804d09 (patch) | |
tree | 6370b8f894c5779bf6c57dd2a4e8fc45d1593e79 /ctree.h | |
parent | 62b79931546bca1b95a4b23ecec8378c372b26f7 (diff) |
Btrfsck: add the ability to prune corrupt extent allocation tree blocks
When we discover bad blocks in the extent allocation tree, repair can
now discard them and recreate the references from the rest of the trees.
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'ctree.h')
-rw-r--r-- | ctree.h | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -802,7 +802,8 @@ struct btrfs_fs_info { u64 bytenr, u64 num_bytes, u64 parent, u64 root_objectid, u64 owner, u64 offset, int refs_to_drop); - struct cache_tree * fsck_extent_cache; + struct cache_tree *fsck_extent_cache; + struct cache_tree *corrupt_blocks; }; /* @@ -1857,6 +1858,14 @@ int btrfs_update_block_group(struct btrfs_trans_handle *trans, struct btrfs_root *root, u64 bytenr, u64 num, int alloc, int mark_free); /* ctree.c */ +int btrfs_del_ptr(struct btrfs_trans_handle *trans, struct btrfs_root *root, + struct btrfs_path *path, int level, int slot); +int btrfs_check_node(struct btrfs_root *root, + struct btrfs_disk_key *parent_key, + struct extent_buffer *buf); +int btrfs_check_leaf(struct btrfs_root *root, + struct btrfs_disk_key *parent_key, + struct extent_buffer *buf); int btrfs_fsck_reinit_root(struct btrfs_trans_handle *trans, struct btrfs_root *root); void reada_for_search(struct btrfs_root *root, struct btrfs_path *path, |