]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: Simplify btrfs_check_super_csum() and get rid of size assumptions
authorJohannes Thumshirn <jthumshirn@suse.de>
Mon, 3 Jun 2019 14:58:55 +0000 (16:58 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 1 Jul 2019 11:35:01 +0000 (13:35 +0200)
commitfba3781772dd5382f90fb32f3789b55d258933f6
treeb45b55b970701ec22c84e2c537db72c9d21debd7
parent53795fb4df2735cf1ebc9b7dd77027330ec32bd0
btrfs: Simplify btrfs_check_super_csum() and get rid of size assumptions

Now that we have already checked for a valid checksum type before
calling btrfs_check_super_csum(), it can be simplified even further.

While at it get rid of the implicit size assumption of the resulting
checksum as well.

This is a preparation for changing all checksum functionality to use the
crypto layer later.

Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/disk-io.c