diff options
author | Qu Wenruo <quwenruo@cn.fujitsu.com> | 2017-06-16 09:43:22 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-06-26 17:09:58 +0200 |
commit | 163ca0e431a72bc48c52c2fd9132e32616b9036a (patch) | |
tree | cd44fc1a2f8c14c73985e0f81e54c5de99b5e0b3 /cmds-check.c | |
parent | 324d4c1857ac8282e838d1fe7c1a9b65b67f0d40 (diff) |
btrfs-progs: check: Fix false alert about EXTENT_DATA that shouldn't be a hole
Since the incompat feature NO_HOLES still allows us to have an explicit
hole file extent, current check is too strict and will cause false
alerts like:
root 5 EXTENT_DATA[257, 0] shouldn't be hole
Fix it by removing the strict file hole extent check.
Link: https://www.spinics.net/lists/linux-btrfs/msg66374.html
Reported-by: Henk Slager <eye1tm@gmail.com>
Tested-by: Henk Slager <eye1tm@gmail.com>
Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'cmds-check.c')
-rw-r--r-- | cmds-check.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/cmds-check.c b/cmds-check.c index ad7c81b2..a7d3ab31 100644 --- a/cmds-check.c +++ b/cmds-check.c @@ -4836,11 +4836,7 @@ static int check_file_extent(struct btrfs_root *root, struct btrfs_key *fkey, } /* Check EXTENT_DATA hole */ - if (no_holes && is_hole) { - err |= FILE_EXTENT_ERROR; - error("root %llu EXTENT_DATA[%llu %llu] shouldn't be hole", - root->objectid, fkey->objectid, fkey->offset); - } else if (!no_holes && *end != fkey->offset) { + if (!no_holes && *end != fkey->offset) { err |= FILE_EXTENT_ERROR; error("root %llu EXTENT_DATA[%llu %llu] interrupt", root->objectid, fkey->objectid, fkey->offset); |