According to btrfs_prepare_device, btrfs file sysstem size should be bigger then 256m.
If mkfs.btrfs specifies the file system size samaller then that, mkfs.btrfs should report error. Signed-off-by: Shen Feng <s...@cn.fujitsu.com> --- mkfs.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/mkfs.c b/mkfs.c index be93aaa..447e8d7 100644 --- a/mkfs.c +++ b/mkfs.c @@ -377,6 +377,10 @@ int main(int ac, char **av) break; case 'b': block_count = parse_size(optarg); + if (block_count < 256*1024*1024) { + fprintf(stderr, "File system size is too small\n"); + exit(1); + } zero_end = 0; break; default: -- 1.6.0.6 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html