24 Mar, 2017
1 commit
-
x86_64 is zero-extending arch so "unsigned int" is preferred over "int"
for address calculations.Space savings:
add/remove: 0/0 grow/shrink: 0/3 up/down: 0/-58 (-58)
function old new delta
xfrm_hash_resize 2752 2743 -9
policy_hash_bysel 985 973 -12
policy_hash_direct 1036 999 -37Signed-off-by: Alexey Dobriyan
Signed-off-by: Steffen Klassert
02 Sep, 2014
1 commit
-
The idea is an extension of the current policy hashing.
Today only non-prefixed policies are stored in a hash table. This
patch relaxes the constraints, and hashes policies whose prefix
lengths are greater or equal to a configurable threshold.Each hash table (one per direction) maintains its own set of IPv4 and
IPv6 thresholds (dbits4, sbits4, dbits6, sbits6), by default (32, 32,
128, 128).Example, if the output hash table is configured with values (16, 24,
56, 64):ip xfrm policy add dir out src 10.22.0.0/20 dst 10.24.1.0/24 ... => hashed
ip xfrm policy add dir out src 10.22.0.0/16 dst 10.24.1.1/32 ... => hashed
ip xfrm policy add dir out src 10.22.0.0/16 dst 10.24.0.0/16 ... => unhashedip xfrm policy add dir out \
src 3ffe:304:124:2200::/60 dst 3ffe:304:124:2401::/64 ... => hashed
ip xfrm policy add dir out \
src 3ffe:304:124:2200::/56 dst 3ffe:304:124:2401::2/128 ... => hashed
ip xfrm policy add dir out \
src 3ffe:304:124:2200::/56 dst 3ffe:304:124:2400::/56 ... => unhashedThe high order bits of the addresses (up to the threshold) are used to
compute the hash key.Signed-off-by: Christophe Gouault
Signed-off-by: Steffen Klassert
20 Oct, 2013
1 commit
-
There are a mix of function prototypes with and without extern
in the kernel sources. Standardize on not using extern for
function prototypes.Function prototypes don't need to be written with extern.
extern is assumed by the compiler. Its use is as unnecessary as
using auto to declare automatic/local variables in a block.Signed-off-by: Joe Perches
Signed-off-by: David S. Miller
16 Apr, 2012
1 commit
-
Use of "unsigned int" is preferred to bare "unsigned" in net tree.
Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller
24 Feb, 2011
1 commit
-
Signed-off-by: David S. Miller
18 May, 2010
1 commit
-
Also added an explicit break; to avoid
a fallthrough in net/ipv4/tcp_input.cSigned-off-by: Joe Perches
Signed-off-by: David S. Miller
21 Apr, 2010
1 commit
-
Sparse can help us find endianness bugs, but we need to make some
cleanups to be able to more easily spot real bugs.Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller
10 Aug, 2009
1 commit
-
This patch fixes hash collisions in cases where number
of entries have incrementing IP source and destination addresses
from single respective subnets (i.e. 192.168.0.1-172.16.0.1,
192.168.0.2-172.16.0.2, and so on.).Signed-off-by: Jussi Maki
Signed-off-by: David S. Miller
04 Oct, 2006
1 commit
-
Src hash is introduced for Mobile IPv6 route optimization usage.
On current kenrel code it is calculated with source address only.
It results we uses the same hash value for outbound state (when
the node has only one address for Mobile IPv6).
This patch use also destination address as peer information for
src hash to be dispersed.Signed-off-by: Masahide NAKAMURA
Signed-off-by: David S. Miller
29 Sep, 2006
1 commit
-
Signed-off-by: Al Viro
Signed-off-by: David S. Miller
23 Sep, 2006
1 commit
-
Signed-off-by: David S. Miller