Skip to content

Commit

Permalink
maple_tree: change return type of mas_split_final_node as void.
Browse files Browse the repository at this point in the history
mas_split_final_node() always returns true and its return value is never
checked.

Change return type to void.

Link: https://lkml.kernel.org/r/20231109160821.16248-2-ppbuk5246@gmail.com
Signed-off-by: Levi Yun <ppbuk5246@gmail.com>
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
  • Loading branch information
Levi Yun authored and Andrew Morton committed Dec 12, 2023
1 parent d19b1a1 commit d9d9bd9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/maple_tree.c
Original file line number Diff line number Diff line change
Expand Up @@ -3132,7 +3132,7 @@ static inline void mas_destroy_rebalance(struct ma_state *mas, unsigned char end
* @mas: The maple state
* @height: The height of the tree in case it's a new root.
*/
static inline bool mas_split_final_node(struct maple_subtree_state *mast,
static inline void mas_split_final_node(struct maple_subtree_state *mast,
struct ma_state *mas, int height)
{
struct maple_enode *ancestor;
Expand All @@ -3156,7 +3156,6 @@ static inline bool mas_split_final_node(struct maple_subtree_state *mast,
mast->l->node = ancestor;
mab_mas_cp(mast->bn, 0, mt_slots[mast->bn->type] - 1, mast->l, true);
mas->offset = mast->bn->b_end - 1;
return true;
}

/*
Expand Down

0 comments on commit d9d9bd9

Please sign in to comment.