summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGui Hecheng <guihc.fnst@cn.fujitsu.com>2014-05-28 18:49:38 +0800
committerDavid Sterba <dsterba@suse.cz>2014-08-22 14:39:33 +0200
commitc63d47653fc61e59f6b7d30b55982e9fe843ceef (patch)
tree9a9fc014594eb79c3e7f93904807312e89d2274e
parentae5c13934e1d93dd000314af5be64e58c00ff716 (diff)
btrfs-progs: fix blindly goto failure for chunk-recover
If the csum of one stripe is not able to judge the order of two device extents, the stripe may happen to belong to the device extent that is already kicked out as ordered. Take this condition into consideration, don't report failure and give more tries with the stripes following. Signed-off-by: Gui Hecheng <guihc.fnst@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz>
-rw-r--r--chunk-recover.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/chunk-recover.c b/chunk-recover.c
index bd37d6e8..dfa7ff63 100644
--- a/chunk-recover.c
+++ b/chunk-recover.c
@@ -1922,10 +1922,9 @@ next_csum:
list_splice_init(&unordered, &chunk->dextents);
btrfs_release_path(&path);
return 0;
- } else
- ret = 1;
+ }
- goto fail_out;
+ goto next_stripe;
}
if (list_is_last(candidates.next, &candidates)) {