]> www.infradead.org Git - users/jedix/linux-maple.git/commit
maple_tree: use height and depth consistently
authorSidhartha Kumar <sidhartha.kumar@oracle.com>
Thu, 27 Feb 2025 20:48:19 +0000 (20:48 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Tue, 4 Mar 2025 05:50:38 +0000 (21:50 -0800)
commit243d40b04d05635b754c4770e0cd547ea83456f9
tree7905057a28402d92ef07bccc9d43d915a1944f97
parent3ffa28bd4cf5d1e5b79c703c4e7e53e92f5478b7
maple_tree: use height and depth consistently

For the maple tree, the root node is defined to have a depth of 0 with a
height of 1.  Each level down from the node, these values are incremented
by 1.  Various code paths define a root with depth 1 which is inconsisent
with the definition.  Modify the code to be consistent with this
definition.

Link: https://lkml.kernel.org/r/20250227204823.758784-3-sidhartha.kumar@oracle.com
Signed-off-by: Sidhartha Kumar <sidhartha.kumar@oracle.com>
Cc: Liam Howlett <liam.howlett@oracle.com>
Cc: Wei Yang <richard.weiyang@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
lib/maple_tree.c