[nacked] maple_tree-use-mas_safe_pivot-to-get-the-pivot-range.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The quilt patch titled
     Subject: maple_tree: use mas_safe_pivot() to get the pivot range
has been removed from the -mm tree.  Its filename was
     maple_tree-use-mas_safe_pivot-to-get-the-pivot-range.patch

This patch was dropped because it was nacked

------------------------------------------------------
From: Wei Yang <richard.weiyang@xxxxxxxxx>
Subject: maple_tree: use mas_safe_pivot() to get the pivot range
Date: Sat, 31 Aug 2024 00:10:52 +0000

Before modifying data, we need to walk the tree to locate the
maple_node. Also we get the range boundary at offset/offset_end.

For the upper boundary at offset, we have defined function
mas_safe_pivot() to get it. Let's leverage it.

Link: https://lkml.kernel.org/r/20240831001053.4751-2-richard.weiyang@xxxxxxxxx
Signed-off-by: Wei Yang <richard.weiyang@xxxxxxxxx>
Cc: Liam R. Howlett <Liam.Howlett@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 lib/maple_tree.c |   16 ++++++----------
 1 file changed, 6 insertions(+), 10 deletions(-)

--- a/lib/maple_tree.c~maple_tree-use-mas_safe_pivot-to-get-the-pivot-range
+++ a/lib/maple_tree.c
@@ -2220,7 +2220,7 @@ static inline void mas_wr_node_walk(stru
 	while (offset < count && mas->index > wr_mas->pivots[offset])
 		offset++;
 
-	wr_mas->r_max = offset < count ? wr_mas->pivots[offset] : mas->max;
+	wr_mas->r_max = mas_safe_pivot(mas, wr_mas->pivots, offset, wr_mas->type);
 	wr_mas->r_min = mas_safe_min(mas, wr_mas->pivots, offset);
 	wr_mas->offset_end = mas->offset = offset;
 }
@@ -3927,11 +3927,9 @@ static inline void mas_wr_extend_null(st
 		    (mas->end != wr_mas->offset_end) &&
 		    !wr_mas->slots[wr_mas->offset_end + 1]) {
 			wr_mas->offset_end++;
-			if (wr_mas->offset_end == mas->end)
-				mas->last = mas->max;
-			else
-				mas->last = wr_mas->pivots[wr_mas->offset_end];
-			wr_mas->end_piv = mas->last;
+			wr_mas->end_piv = mas->last =
+				mas_safe_pivot(mas, wr_mas->pivots,
+					wr_mas->offset_end, wr_mas->type);
 		}
 	}
 
@@ -3956,10 +3954,8 @@ static inline void mas_wr_end_piv(struct
 	       (wr_mas->mas->last > wr_mas->pivots[wr_mas->offset_end]))
 		wr_mas->offset_end++;
 
-	if (wr_mas->offset_end < wr_mas->mas->end)
-		wr_mas->end_piv = wr_mas->pivots[wr_mas->offset_end];
-	else
-		wr_mas->end_piv = wr_mas->mas->max;
+	wr_mas->end_piv = mas_safe_pivot(wr_mas->mas, wr_mas->pivots,
+				wr_mas->offset_end, wr_mas->type);
 }
 
 static inline unsigned char mas_wr_new_end(struct ma_wr_state *wr_mas)
_

Patches currently in -mm which might be from richard.weiyang@xxxxxxxxx are

maple_tree-arange64-node-is-not-a-leaf-node.patch
maple_tree-dump-error-message-based-on-format.patch
maple_tree-cleanup-function-descriptions.patch
maple_tree-fix-comment-typo-on-ma_flag-of-allocation-tree.patch
maple_tree-local-variable-count-is-not-necessary.patch





[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux