]> www.infradead.org Git - users/jedix/linux-maple.git/commit
maple_tree: Clean up mas_parent_enum()
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 15 Nov 2022 14:29:33 +0000 (09:29 -0500)
committerLiam R. Howlett <Liam.Howlett@oracle.com>
Tue, 13 Dec 2022 21:03:40 +0000 (16:03 -0500)
commit24894ad8ac47e4eeb2299df90b95f66881633dc3
tree16499591a90d0784915f7bd6b7a2cd0251715790
parente79a0227b405068289b07175c312fa5b93b20998
maple_tree: Clean up mas_parent_enum()

mas_parent_enum() is a simple wrapper for mte_parent_enum() which is
only called from that wrapper.  Remove the wrapper and inline
mte_parent_enum() into mas_parent_enum().

At the same time, clean up the bit masking of the root pointer since it
cannot be set by the time the bit masking occurs.  Change the check on
the root bit to a WARN_ON(), and fix the verification code to not
trigger the WARN_ON() before checking if the node is root.

Reported-by: Wei Yang <richard.weiyang@gmail.com>
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
lib/maple_tree.c