diff options
author | Alexander Duyck <alexander.h.duyck@redhat.com> | 2015-03-04 15:04:03 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-03-04 23:35:18 -0500 |
commit | 71e8b67d0fdd2fe22a657bb98716c5cf0e31e828 (patch) | |
tree | 5e5ab78f315e6cd7bc001a6627f2e3577e626301 /net/ipv4/raw.c | |
parent | a7e53531234dc206bb75abb5305a72665dd4d75d (diff) |
fib_trie: Update last spot w/ idx >> n->bits code and explanation
This change updates the fib_table_lookup function so that it is in sync
with the fib_find_node function in terms of the explanation for the index
check based on the bits value.
I have also updated it from doing a mask to just doing a compare as I have
found that seems to provide more options to the compiler as I have seen it
turn this into a shift of the value and test under some circumstances.
In addition I addressed one minor issue in which we kept computing the key
^ n->key when checking the fib aliases. I pulled the xor out of the loop
in order to reduce the number of memory reads in the lookup. As a result
we should save a couple cycles since the xor is only done once much earlier
in the lookup.
Signed-off-by: Alexander Duyck <alexander.h.duyck@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/raw.c')
0 files changed, 0 insertions, 0 deletions