]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: set BTRFS_FS_STATE_NO_CSUMS if we fail to load the csum root
authorJosef Bacik <josef@toxicpanda.com>
Fri, 5 Nov 2021 20:45:47 +0000 (16:45 -0400)
committerDavid Sterba <dsterba@suse.com>
Mon, 3 Jan 2022 14:09:49 +0000 (15:09 +0100)
commitfdfd8c794919a0c45afedaee1cfe08d7bffeb6cc
tree3ecf993849b50b264139c3098bce90a23b956f7e
parent6cbad3397a0c1752ff65665bf1b8d3e2be042d64
btrfs: set BTRFS_FS_STATE_NO_CSUMS if we fail to load the csum root

We have a few places where we skip doing csums if we mounted with one of
the rescue options that ignores bad csum roots.  In the future when
there are multiple csum roots it'll be costly to check and see if there
are any missing csum roots, so simply add a flag to indicate the fs
should skip loading csums in case of errors.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/compression.c
fs/btrfs/ctree.h
fs/btrfs/disk-io.c
fs/btrfs/file-item.c
fs/btrfs/inode.c