Commit ef5c3de5 authored by Liam R. Howlett's avatar Liam R. Howlett Committed by Andrew Morton

maple_tree: fix node allocation testing on 32 bit

Internal node counting was altered and the 64 bit test was updated,
however the 32bit test was missed.

Restore the 32bit test to a functional state.

Link: https://lore.kernel.org/linux-mm/CAMuHMdV4T53fOw7VPoBgPR7fP6RYqf=CBhD_y_vOg53zZX_DnA@mail.gmail.com/
Link: https://lkml.kernel.org/r/20230712173916.168805-2-Liam.Howlett@oracle.com
Fixes: 541e06b7 ("maple_tree: remove GFP_ZERO from kmem_cache_alloc() and kmem_cache_alloc_bulk()")
Signed-off-by: default avatarLiam R. Howlett <Liam.Howlett@oracle.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 7a93c71a
...@@ -206,9 +206,9 @@ static noinline void __init check_new_node(struct maple_tree *mt) ...@@ -206,9 +206,9 @@ static noinline void __init check_new_node(struct maple_tree *mt)
e = i - 1; e = i - 1;
} else { } else {
if (i >= 4) if (i >= 4)
e = i - 4; e = i - 3;
else if (i == 3) else if (i >= 1)
e = i - 2; e = i - 1;
else else
e = 0; e = 0;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment