From: Liam R. Howlett Date: Fri, 22 Jan 2021 19:38:29 +0000 (-0500) Subject: maple_tree: Fix MTREE_INIT X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=c27177c3df7ffecca54d4896e6df114c30051b73;p=users%2Fjedix%2Flinux-maple.git maple_tree: Fix MTREE_INIT Signed-off-by: Liam R. Howlett --- diff --git a/lib/maple_tree.c b/lib/maple_tree.c index 8809e750d195..b529bff1c1ad 100644 --- a/lib/maple_tree.c +++ b/lib/maple_tree.c @@ -5156,12 +5156,14 @@ static void mt_destroy_walk(struct rcu_head *head) void **slots; struct maple_node *node = container_of(head, struct maple_node, rcu); struct maple_enode *start; - struct maple_tree mt = MTREE_INIT(mt, node->ma_flags); - MA_STATE(mas, &mt, 0, 0); + struct maple_tree mt; + MA_STATE(mas, NULL, 0, 0); if (ma_is_leaf(node->type)) goto free_leaf; + mtree_init(&mt, node->ma_flags); + mas.tree = &mt; start = mt_mk_node(node, node->type); mas.node = start; slots = mas_destroy_descend(&mas);