]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
maple_tree: use ma_is_root() in mas_replace().
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 9 Feb 2021 00:34:00 +0000 (19:34 -0500)
committerLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 9 Feb 2021 00:34:00 +0000 (19:34 -0500)
Instead of using mte_is_root(), use ma_is_root() directly since the maple node
is known already.

Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
lib/maple_tree.c

index 10de480cf6ec3215dae23ffa3bf4883edc4b482e..76b84ec4f1bf19de6e67a9043de7351d55e0b529 100644 (file)
@@ -1483,7 +1483,7 @@ static inline void mas_replace(struct ma_state *mas, bool advanced)
        void **slots = NULL;
 
 
-       if (mte_is_root(mas->node)) {
+       if (ma_is_root(mn)) {
                old_enode = mas_root_locked(mas);
        } else {
                offset = mte_parent_slot(mas->node);