]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
maple_tree: Remove unnecessary check from next_nentry
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 8 Sep 2020 15:27:48 +0000 (11:27 -0400)
committerLiam R. Howlett <Liam.Howlett@Oracle.com>
Fri, 30 Oct 2020 19:11:12 +0000 (15:11 -0400)
Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
lib/maple_tree.c

index 74354f7f0e8cc3ab8debc6978b1e8fd7a7bb8e7d..441117fd6d082aeda70ce8f1bef319abc386ee17 100644 (file)
@@ -3272,11 +3272,7 @@ static inline bool mas_next_nentry(struct ma_state *mas, unsigned long max,
 
        while (slot < count) {
                pivot = mas_safe_pivot(mas, slot);
-
-               if (pivot > mas->max) // possibly a retry.
-                       goto no_entry;
-
-               if (slot != 0 && pivot == 0)
+               if (!pivot && slot)
                        goto no_entry;
 
                if (r_start > max)