]> git.baikalelectronics.ru Git - kernel.git/commit
net: some optimizations in af_inet
authorEric Dumazet <dada1@cosmosbay.com>
Sun, 23 Nov 2008 23:42:23 +0000 (15:42 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 23 Nov 2008 23:42:23 +0000 (15:42 -0800)
commit5c6acbd8d52fc3d32d6365d1e6f878629310e3de
tree948bf0a108717265df6228bcac2126ec423cb988
parent936ce085daab05f4adbc71e3e8beb5b340fa6a98
net: some optimizations in af_inet

1) Use eq_net() in inet_netns_ok() to speedup socket creation if
   !CONFIG_NET_NS

2) Reorder the tests about inet_ehash_secret generation (once only)
   Use the unlikely() macro when testing if inet_ehash_secret already
   generated.

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/af_inet.c