]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
btrfs: untangle gotos a bit in __clear_extent_bit
authorDavid Sterba <dsterba@suse.com>
Tue, 26 Apr 2016 23:02:15 +0000 (01:02 +0200)
committerDavid Sterba <dsterba@suse.com>
Fri, 29 Apr 2016 09:01:47 +0000 (11:01 +0200)
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent_io.c

index f5eda54e225fa1d3cfa8e19306100642109d05a6..3ecd8b1f239fccfaf277c7bf50e215440610a534 100644 (file)
@@ -726,14 +726,6 @@ next:
        start = last_end + 1;
        if (start <= end && state && !need_resched())
                goto hit_next;
-       goto search_again;
-
-out:
-       spin_unlock(&tree->lock);
-       if (prealloc)
-               free_extent_state(prealloc);
-
-       return 0;
 
 search_again:
        if (start > end)
@@ -742,6 +734,14 @@ search_again:
        if (gfpflags_allow_blocking(mask))
                cond_resched();
        goto again;
+
+out:
+       spin_unlock(&tree->lock);
+       if (prealloc)
+               free_extent_state(prealloc);
+
+       return 0;
+
 }
 
 static void wait_on_state(struct extent_io_tree *tree,