summaryrefslogtreecommitdiff
path: root/utils.c
diff options
context:
space:
mode:
authorJosef Bacik <josef@redhat.com>2010-12-09 18:27:03 +0000
committerChris Mason <chris.mason@oracle.com>2011-10-25 09:18:31 -0400
commite2a6859d93254ee0cdb2bf575aa23b624bc735e5 (patch)
tree58f5deeb461d342668c3c52162f2a1be7a7406b5 /utils.c
parent17cf679fb3622a9e3452777d07fcf3a346266ff1 (diff)
Btrfs-progs: update super fields for space cache
This patch updates the super field to add the cache_generation member. It also makes us set it to -1 on mkfs so any new filesystem will get the space cache stuff turned on. Thanks, Signed-off-by: Josef Bacik <josef@redhat.com> Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'utils.c')
-rw-r--r--utils.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/utils.c b/utils.c
index 2a15d866..35e17b8b 100644
--- a/utils.c
+++ b/utils.c
@@ -107,6 +107,7 @@ int make_btrfs(int fd, const char *device, const char *label,
btrfs_set_super_stripesize(&super, stripesize);
btrfs_set_super_csum_type(&super, BTRFS_CSUM_TYPE_CRC32);
btrfs_set_super_chunk_root_generation(&super, 1);
+ btrfs_set_super_cache_generation(&super, -1);
if (label)
strncpy(super.label, label, BTRFS_LABEL_SIZE - 1);