aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/ctree.h
diff options
context:
space:
mode:
authorJosef Bacik <jbacik@fb.com>2014-05-07 17:06:09 -0400
committerChris Mason <clm@fb.com>2014-06-09 20:20:49 -0400
commitfaa2dbf004e89e8f7ccd28fbe6f07c308417b8ae (patch)
treeb700876fe08b8830d4e8686c039f4241cc9cb5e2 /fs/btrfs/ctree.h
parentfcebe4562dec83b3f8d3088d77584727b09130b2 (diff)
Btrfs: add sanity tests for new qgroup accounting code
This exercises the various parts of the new qgroup accounting code. We do some basic stuff and do some things with the shared refs to make sure all that code works. I had to add a bunch of infrastructure because I needed to be able to insert items into a fake tree without having to do all the hard work myself, hopefully this will be usefull in the future. Thanks, Signed-off-by: Josef Bacik <jbacik@fb.com> Signed-off-by: Chris Mason <clm@fb.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r--fs/btrfs/ctree.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index 06cc384933cc..4896d7a947eb 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -1798,6 +1798,10 @@ struct btrfs_root {
1798 1798
1799 u64 highest_objectid; 1799 u64 highest_objectid;
1800 1800
1801#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS
1802 u64 alloc_bytenr;
1803#endif
1804
1801 u64 defrag_trans_start; 1805 u64 defrag_trans_start;
1802 struct btrfs_key defrag_progress; 1806 struct btrfs_key defrag_progress;
1803 struct btrfs_key defrag_max; 1807 struct btrfs_key defrag_max;
@@ -4111,6 +4115,8 @@ static inline int btrfs_defrag_cancelled(struct btrfs_fs_info *fs_info)
4111/* Sanity test specific functions */ 4115/* Sanity test specific functions */
4112#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS 4116#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS
4113void btrfs_test_destroy_inode(struct inode *inode); 4117void btrfs_test_destroy_inode(struct inode *inode);
4118int btrfs_verify_qgroup_counts(struct btrfs_fs_info *fs_info, u64 qgroupid,
4119 u64 rfer, u64 excl);
4114#endif 4120#endif
4115 4121
4116#endif 4122#endif