Skip to contentSkip to conversation

rhashtable: remove duplicate comment.

PATCH In review NeilBrown 2 participants 2 messages Sep 11, 2014

Subsystems (2)
lore
Share & tools
lore

NeilBrown

author
#0 lore raw

PATCH 1/1 rhashtable: remove duplicate comment.

The second comment is identical to the earlier comment, just indented a bit. This is confusing, so remove it.

Also expand that first comment to mention the splicing that happens.

lib/rhashtable.c +2 -5
index a2c78810ebc1..8fd2f21d022a 100644
@@ -309,15 +309,12 @@ int rhashtable_shrink(struct rhashtable *ht, gfp_t flags)
 
 	/* Link each bucket in the new table to the first bucket
 	 * in the old table that contains entries which will hash
-	 * to the new bucket.
+	 * to the new bucket, and then splice in the second
+	 * bucket from the old table.
 	 */
 	for (i = 0; i < ntbl->size; i++) {
 		ntbl->buckets[i] = tbl->buckets[i];
 
-		/* Link each bucket in the new table to the first bucket
-		 * in the old table that contains entries which will hash
-		 * to the new bucket.
-		 */
 		for (pprev = &ntbl->buckets[i]; *pprev != NULL;
 		     pprev = &rht_dereference(*pprev, ht)->next)
 			;