rhashtable: optimize rhashtable_lookup routine
authorYing Xue <ying.xue@windriver.com>
Wed, 7 Jan 2015 05:41:52 +0000 (13:41 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 9 Jan 2015 03:47:09 +0000 (19:47 -0800)
commitefb975a67ea7846b966080f999589de570686aa0
tree90788e6749778a352d8245c4b9c1fc6282e9bfb3
parent7c1b70234ed49b3ea9df079a1d3a5763e660304b
rhashtable: optimize rhashtable_lookup routine

Define an internal compare function and relevant compare argument,
and then make use of rhashtable_lookup_compare() to lookup key in
hash table, reducing duplicated code between rhashtable_lookup()
and rhashtable_lookup_compare().

Signed-off-by: Ying Xue <ying.xue@windriver.com>
Cc: Thomas Graf <tgraf@suug.ch>
Acked-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
lib/rhashtable.c