tipc: Convert node object array to a hash table
authorAllan Stephens <allan.stephens@windriver.com>
Fri, 25 Feb 2011 23:42:52 +0000 (18:42 -0500)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Sun, 13 Mar 2011 20:35:17 +0000 (16:35 -0400)
commit672d99e19a12b703c9e2d71ead8fb8b8a85a3886
treecca078684f8adee7450cadcb565176f0a8b111ff
parentf831c963b5c20bec230edce89e25f369996be5db
tipc: Convert node object array to a hash table

Replaces the dynamically allocated array of pointers to the cluster's
node objects with a static hash table. Hash collisions are resolved
using chaining, with a typical hash chain having only a single node,
to avoid degrading performance during processing of incoming packets.
The conversion to a hash table reduces the memory requirements for
TIPC's node table to approximately the same size it had prior to
the previous commit.

In addition to the hash table itself, TIPC now also maintains a
linked list for the node objects, sorted by ascending network address.
This list allows TIPC to continue sending responses to user space
applications that request node and link information in sorted order.
The list also improves performance when name table update messages are
sent by making it easier to identify the nodes that must be notified.

Signed-off-by: Allan Stephens <allan.stephens@windriver.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
net/tipc/name_distr.c
net/tipc/net.c
net/tipc/net.h
net/tipc/node.c
net/tipc/node.h
This page took 0.031328 seconds and 5 git commands to generate.