]> www.infradead.org Git - users/jedix/linux-maple.git/commit
maple_tree: Rework mas_replace()
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Wed, 3 Feb 2021 14:35:43 +0000 (09:35 -0500)
committerLiam R. Howlett <Liam.Howlett@Oracle.com>
Wed, 3 Feb 2021 16:24:57 +0000 (11:24 -0500)
commit9996c8e044a9e87cc543b3259caf5c2827acd35f
treeadb61502233a2aea132c2df688c0973c3b33fe9d
parente97ce59d99c3775fb1c8dc198b0bfb33899b291e
maple_tree: Rework mas_replace()

Drop ma_set_slot() and mte_set_slot() in favour of just setting the slot
value in the parent.  This is the only function using those two
functions and they are not necessary.

Drop check for replacing the node with itself as that doesn't happen -
confirmed by running the test suite with a BUG_ON instead of the swap.

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