summaryrefslogtreecommitdiff
path: root/ctree.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-04-04 15:42:17 -0400
committerDavid Woodhouse <dwmw2@hera.kernel.org>2008-04-04 15:42:17 -0400
commita37e1e720451664477b030242616b3e48d31013e (patch)
treee47d2a0956b071d1483427bae0f4e90e8a32cf55 /ctree.c
parenta57a255e442c8d8d3c1c28780af84483c3b5ec21 (diff)
Recow all roots at the end of mkfs
The mkfs code bootstraps the filesystem on a single device. Once the raid block groups are setup, it needs to recow all of the blocks so that each tree is properly allocated.
Diffstat (limited to 'ctree.c')
-rw-r--r--ctree.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/ctree.c b/ctree.c
index 5e423754..051cab59 100644
--- a/ctree.c
+++ b/ctree.c
@@ -244,11 +244,8 @@ int btrfs_cow_block(struct btrfs_trans_handle *trans,
(unsigned long long)root->fs_info->generation);
WARN_ON(1);
}
- if (btrfs_header_generation(buf) == trans->transid) {
-#if 0
- &&
+ if (btrfs_header_generation(buf) == trans->transid &&
!btrfs_header_flag(buf, BTRFS_HEADER_FLAG_WRITTEN)) {
-#endif
*cow_ret = buf;
return 0;
}