diff --git a/lib/maple_tree.c b/lib/maple_tree.c index 00524e55a21e..34b84b14985e 100644 --- a/lib/maple_tree.c +++ b/lib/maple_tree.c @@ -4560,15 +4560,12 @@ static void *mas_prev_slot(struct ma_state *mas, unsigned long min, bool empty) if (unlikely(mas_rewalk_if_dead(mas, node, save_point))) goto retry; - if (likely(entry)) return entry; if (!empty) { - if (mas->index <= min) { - mas->status = ma_underflow; - return NULL; - } + if (mas->index <= min) + goto underflow; goto again; }