summaryrefslogtreecommitdiff
path: root/mkfs.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2007-04-09 10:42:55 -0400
committerDavid Woodhouse <dwmw2@hera.kernel.org>2007-04-09 10:42:55 -0400
commit86c2d787286b888a7f45ee522310f773b8466917 (patch)
tree9c235434475c25dff72cf8ce284bf163c73a6f3b /mkfs.c
parent8accdae27a678a47f021128121f2975e6fc25201 (diff)
groundwork for subvolume and snapshot roots
Diffstat (limited to 'mkfs.c')
-rw-r--r--mkfs.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/mkfs.c b/mkfs.c
index f182a190..c94dbf9c 100644
--- a/mkfs.c
+++ b/mkfs.c
@@ -120,6 +120,7 @@ int mkfs(int fd, u64 num_blocks, u32 blocksize)
u32 itemoff;
u32 start_block = BTRFS_SUPER_INFO_OFFSET / blocksize;
+ btrfs_set_super_generation(&super, 1);
btrfs_set_super_blocknr(&super, start_block);
btrfs_set_super_root(&super, start_block + 1);
strcpy((char *)(&super.magic), BTRFS_MAGIC);