diff options
author | Josef Bacik <josef@redhat.com> | 2010-09-21 14:21:34 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2010-10-29 09:26:36 -0400 |
commit | 88c2ba3b069f1e0f4694124d02985fa7620a19f1 (patch) | |
tree | e41859aca299e14e2658d75e2bf1ef2aea9ab077 /fs/btrfs/free-space-cache.c | |
parent | 67377734fd24c32cbdfeb697c2e2bd7fed519e75 (diff) |
Btrfs: Add a clear_cache mount option
If something goes wrong with the free space cache we need a way to make sure
it's not loaded on mount and that it's cleared for everybody. When you pass the
clear_cache option it will make it so all block groups are setup to be cleared,
which keeps them from being loaded and then they will be truncated when the
transaction is committed. Thanks,
Signed-off-by: Josef Bacik <josef@redhat.com>
Diffstat (limited to 'fs/btrfs/free-space-cache.c')
-rw-r--r-- | fs/btrfs/free-space-cache.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c index baa193423fb8..22ee0dc2e6b8 100644 --- a/fs/btrfs/free-space-cache.c +++ b/fs/btrfs/free-space-cache.c | |||
@@ -242,8 +242,6 @@ int load_free_space_cache(struct btrfs_fs_info *fs_info, | |||
242 | */ | 242 | */ |
243 | spin_lock(&block_group->lock); | 243 | spin_lock(&block_group->lock); |
244 | if (block_group->disk_cache_state != BTRFS_DC_WRITTEN) { | 244 | if (block_group->disk_cache_state != BTRFS_DC_WRITTEN) { |
245 | printk(KERN_ERR "not reading block group %llu, dcs is %d\n", block_group->key.objectid, | ||
246 | block_group->disk_cache_state); | ||
247 | spin_unlock(&block_group->lock); | 245 | spin_unlock(&block_group->lock); |
248 | return 0; | 246 | return 0; |
249 | } | 247 | } |