Btrfs: fix OOPS of empty filesystem after balance
authorliubo <liubo2009@cn.fujitsu.com>
Mon, 7 Mar 2011 02:13:14 +0000 (02:13 +0000)
committerroot <Chris Mason chris.mason@oracle.com>
Mon, 28 Mar 2011 09:37:53 +0000 (05:37 -0400)
btrfs will remove unused block groups after balance.
When a empty filesystem is balanced, the block group with tag "DATA" may be
dropped, and after umount and mount again, it will not find "DATA" space_info
and lead to OOPS.
So we initial the necessary space_infos(DATA, SYSTEM, METADATA) to avoid OOPS.

Reported-by: Daniel J Blueman <daniel.blueman@gmail.com>
Signed-off-by: Liu Bo <liubo2009@cn.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>

No differences found