Thread (5 messages) 5 messages, 3 authors, 2004-09-27

Re: [5/6]: Dynamic neigh hash table growth

From: Krishna Kumar <hidden>
Date: 2004-09-24 20:11:58




In neigh_hash_grow(), next need not be set to NULL.

thx,

- KK
+   for (i = 0; i < old_entries; i++) {
+      struct neighbour *n, *next;
+
+      next = NULL;
+      for (n = old_hash[i]; n; n = next) {
+         unsigned int hash_val = tbl->hash(n->primary_key, n->dev);
+
+         hash_val &= new_hash_mask;
+         next = n->next;
+
+         n->next = new_hash[hash_val];
+         new_hash[hash_val] = n;
+      }
+   }
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help