Skip to contentSkip to conversation

+ rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch added to -mm tree

PATCH [email protected] 1 participant 1 message Nov 7, 2013 Library code

lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

Subject: + rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch added to -mm tree
To: [email protected],[email protected],[email protected]
From: [email protected]
Date: Thu, 07 Nov 2013 14:16:51 -0800

The patch titled
Subject: rbtree/test: test rbtree_postorder_for_each_entry_safe()
has been added to the -mm tree. Its filename is
rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch

This patch should soon appear at
http://ozlabs.org/~akpm/mmots/broken-out/rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch
and later at
http://ozlabs.org/~akpm/mmotm/broken-out/rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch

Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated there every 3-4 working days

------------------------------------------------------
From: Cody P Schafer <[email protected]>
Subject: rbtree/test: test rbtree_postorder_for_each_entry_safe()

---

 lib/rbtree_test.c |   11 +++++++++++
 1 file changed, 11 insertions(+)
lib/rbtree_test.c renamed from lib/rbtree_test.c~rbtree-test-test-rbtree_postorder_for_each_entry_safe +11 -0
diff -puN lib/rbtree_test.c~rbtree-test-test-rbtree_postorder_for_each_entry_safe lib/rbtree_test.c
@@ -114,6 +114,16 @@ static int black_path_count(struct rb_no
 	return count;
 }
 
+static void check_postorder_foreach(int nr_nodes)
+{
+	struct test_node *cur, *n;
+	int count = 0;
+	rbtree_postorder_for_each_entry_safe(cur, n, &root, rb)
+		count++;
+
+	WARN_ON_ONCE(count != nr_nodes);
+}
+
 static void check_postorder(int nr_nodes)
 {
 	struct rb_node *rb;
@@ -148,6 +158,7 @@ static void check(int nr_nodes)
 	WARN_ON_ONCE(count < (1 << black_path_count(rb_last(&root))) - 1);
 
 	check_postorder(nr_nodes);
+	check_postorder_foreach(nr_nodes);
 }
 
 static void check_augmented(int nr_nodes)

_

Patches currently in -mm which might be from [email protected] are

bitops-find-clarify-and-extend-documentation.patch
linux-next.patch
rbtree-fix-rbtree_postorder_for_each_entry_safe-iterator.patch rbtree-test-move-rb_node-to-the-middle-of-the-test-struct.patch rbtree-test-test-rbtree_postorder_for_each_entry_safe.patch net-netfilter-ipset-ip_set_hash_netifacec-use-rbtree-postorder-iteration-instead-of-opencoding.patch fs-ubifs-use-rbtree-postorder-iteration-helper-instead-of-opencoding.patch fs-ext4-use-rbtree-postorder-iteration-helper-instead-of-opencoding.patch fs-jffs2-use-rbtree-postorder-iteration-helper-instead-of-opencoding.patch fs-ext3-use-rbtree-postorder-iteration-helper-instead-of-opencoding.patch drivers-mtd-ubi-use-rbtree-postorder-iteration-helper-instead-of-opencoding.patch arch-sh-kernel-dwarfc-use-rbtree-postorder-iteration-helper-instead-of-solution-using-repeated-rb_erase.patch