maple_tree: root node could be handled by !p_slot too
authorWei Yang <richard.weiyang@gmail.com>
Fri, 13 Sep 2024 06:31:28 +0000 (06:31 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Thu, 7 Nov 2024 04:11:13 +0000 (20:11 -0800)
commit0cc8d68abe2fdcb7039ece95f784698c0b0dc51e
tree60d085a3b921ba09b0d481fda0a79740c6bf70d5
parent0f85eb3395c74d7cc823169bbacc670c6645ae80
maple_tree: root node could be handled by !p_slot too

For a root node, mte_parent_slot() return 0, this exactly fits the
following !p_slot check.

So we can remove the special handling for root node.

Link: https://lkml.kernel.org/r/20240913063128.27391-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
Reviewed-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
lib/maple_tree.c