diff options
author | David Sterba <dsterba@suse.cz> | 2013-04-30 18:51:58 +0200 |
---|---|---|
committer | Josef Bacik <jbacik@fusionio.com> | 2013-06-14 17:29:18 +0200 |
commit | e6d2960582f625ba6e676117019b62aa87425e8f (patch) | |
tree | ef7a26fbfd2dbd8ab7891dc9a95d4294846f3271 /fs/btrfs | |
parent | btrfs: add prefix to sanity tests messages (diff) | |
download | linux-e6d2960582f625ba6e676117019b62aa87425e8f.tar.xz linux-e6d2960582f625ba6e676117019b62aa87425e8f.zip |
btrfs: move ifdef around sanity checks out of init_btrfs_fs
Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/free-space-cache.c | 4 | ||||
-rw-r--r-- | fs/btrfs/free-space-cache.h | 2 | ||||
-rw-r--r-- | fs/btrfs/super.c | 2 |
3 files changed, 3 insertions, 5 deletions
diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c index 02c4d38f9e50..ed26a5793cf7 100644 --- a/fs/btrfs/free-space-cache.c +++ b/fs/btrfs/free-space-cache.c @@ -3490,4 +3490,6 @@ out: test_msg("Free space cache tests finished\n"); } #undef test_msg -#endif /* CONFIG_BTRFS_FS_RUN_SANITY_TESTS */ +#else /* !CONFIG_BTRFS_FS_RUN_SANITY_TESTS */ +void btrfs_test_free_space_cache(void) {} +#endif /* !CONFIG_BTRFS_FS_RUN_SANITY_TESTS */ diff --git a/fs/btrfs/free-space-cache.h b/fs/btrfs/free-space-cache.h index 8b7f19f44961..894116b71304 100644 --- a/fs/btrfs/free-space-cache.h +++ b/fs/btrfs/free-space-cache.h @@ -113,8 +113,6 @@ int btrfs_return_cluster_to_free_space( int btrfs_trim_block_group(struct btrfs_block_group_cache *block_group, u64 *trimmed, u64 start, u64 end, u64 minlen); -#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS void btrfs_test_free_space_cache(void); -#endif #endif diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c index f0857e092a3c..107c6e23cbc0 100644 --- a/fs/btrfs/super.c +++ b/fs/btrfs/super.c @@ -1733,9 +1733,7 @@ static int __init init_btrfs_fs(void) btrfs_init_lockdep(); -#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS btrfs_test_free_space_cache(); -#endif printk(KERN_INFO "%s loaded\n", BTRFS_BUILD_VERSION); return 0; |