btrfs-progs: add three more validation checks for superblock
authorLiu Bo <bo.li.liu@oracle.com>
Wed, 11 May 2016 13:40:07 +0000 (15:40 +0200)
committerDavid Sterba <dsterba@suse.com>
Wed, 11 May 2016 14:37:45 +0000 (16:37 +0200)
commitdf2236d73bdffd69cf6d9aac7d80c880b4413aaa
treed07a3a3eaca5c1237c7155b3e3122c16745812d2
parent9988284574c1692e5181ecd6f8b9e2512b0503ae
btrfs-progs: add three more validation checks for superblock

This adds validation checks for super_total_bytes, super_bytes_used and
super_stripesize.

Since these checks are made after superblock finishes checksum

 checking, this also adds a notice of "superblock checksum matches but..".

Reported-by: Vegard Nossum <vegard.nossum@oracle.com>
Reported-by: Quentin Casasnovas <quentin.casasnovas@oracle.com>
Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
[ adjusted message wording ]
Signed-off-by: David Sterba <dsterba@suse.com>
disk-io.c