On 03/06/2013 07:56 AM, David Sterba wrote:
The superblock checksum is not verified upon mount. <awkward silence> Add that check and also reorder existing checks to a more logical order. Current mkfs.btrfs does not calculate the correct checksum of super_block and thus a freshly created filesytem will fail to mount when this patch is applied. First transaction commit calculates correct superblock checksum and saves it to disk.
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 7d84651..d5c710c 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c @@ -354,6 +354,42 @@ out: } /* + * Return 0 if the superblock checksum type matches the checksum value of that + * alghorithm. Pass the raw disk superblock data.
I'm not familiar with the review policy on this list, but here's a minor one:
s/alghorithm/algorithm/ Blair -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
