Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b5a4ba14 authored by David Sterba's avatar David Sterba
Browse files

btrfs: untangle gotos a bit in __set_extent_bit



Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 2c53b912
Loading
Loading
Loading
Loading
+7 −8
Original line number Diff line number Diff line
@@ -1037,7 +1037,13 @@ __set_extent_bit(struct extent_io_tree *tree, u64 start, u64 end,
		goto out;
	}

	goto search_again;
search_again:
	if (start > end)
		goto out;
	spin_unlock(&tree->lock);
	if (gfpflags_allow_blocking(mask))
		cond_resched();
	goto again;

out:
	spin_unlock(&tree->lock);
@@ -1046,13 +1052,6 @@ __set_extent_bit(struct extent_io_tree *tree, u64 start, u64 end,

	return err;

search_again:
	if (start > end)
		goto out;
	spin_unlock(&tree->lock);
	if (gfpflags_allow_blocking(mask))
		cond_resched();
	goto again;
}

int set_extent_bit(struct extent_io_tree *tree, u64 start, u64 end,