summaryrefslogtreecommitdiff
path: root/init
diff options
context:
space:
mode:
authorWang Shilong <wangsl.fnst@cn.fujitsu.com>2014-05-13 17:05:06 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-06-30 20:09:46 -0700
commit2d857bc05efe3654da84dec0a1199e8ec4bf6e22 (patch)
tree259cf3038b882b5cf3c39bc620dd337542932ad7 /init
parent372fad07b99cc6a9959bfe6b8f46135970c52a21 (diff)
downloadlinux-3.10-2d857bc05efe3654da84dec0a1199e8ec4bf6e22.tar.gz
linux-3.10-2d857bc05efe3654da84dec0a1199e8ec4bf6e22.tar.bz2
linux-3.10-2d857bc05efe3654da84dec0a1199e8ec4bf6e22.zip
Btrfs: set right total device count for seeding support
commit 298658414a2f0bea1f05a81876a45c1cd96aa2e0 upstream. Seeding device support allows us to create a new filesystem based on existed filesystem. However newly created filesystem's @total_devices should include seed devices. This patch fix the following problem: # mkfs.btrfs -f /dev/sdb # btrfstune -S 1 /dev/sdb # mount /dev/sdb /mnt # btrfs device add -f /dev/sdc /mnt --->fs_devices->total_devices = 1 # umount /mnt # mount /dev/sdc /mnt --->fs_devices->total_devices = 2 This is because we record right @total_devices in superblock, but @fs_devices->total_devices is reset to be 0 in btrfs_prepare_sprout(). Fix this problem by not resetting @fs_devices->total_devices. Signed-off-by: Wang Shilong <wangsl.fnst@cn.fujitsu.com> Signed-off-by: Chris Mason <clm@fb.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions