aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/tcp.c')
-rw-r--r--net/ipv4/tcp.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
index 64d0af675823..cf13726259cd 100644
--- a/net/ipv4/tcp.c
+++ b/net/ipv4/tcp.c
@@ -2865,11 +2865,10 @@ void __init tcp_init(void)
2865 (totalram_pages >= 128 * 1024) ? 2865 (totalram_pages >= 128 * 1024) ?
2866 13 : 15, 2866 13 : 15,
2867 0, 2867 0,
2868 &tcp_hashinfo.ehash_size,
2869 NULL, 2868 NULL,
2869 &tcp_hashinfo.ehash_mask,
2870 thash_entries ? 0 : 512 * 1024); 2870 thash_entries ? 0 : 512 * 1024);
2871 tcp_hashinfo.ehash_size = 1 << tcp_hashinfo.ehash_size; 2871 for (i = 0; i <= tcp_hashinfo.ehash_mask; i++) {
2872 for (i = 0; i < tcp_hashinfo.ehash_size; i++) {
2873 INIT_HLIST_NULLS_HEAD(&tcp_hashinfo.ehash[i].chain, i); 2872 INIT_HLIST_NULLS_HEAD(&tcp_hashinfo.ehash[i].chain, i);
2874 INIT_HLIST_NULLS_HEAD(&tcp_hashinfo.ehash[i].twchain, i); 2873 INIT_HLIST_NULLS_HEAD(&tcp_hashinfo.ehash[i].twchain, i);
2875 } 2874 }
@@ -2878,7 +2877,7 @@ void __init tcp_init(void)
2878 tcp_hashinfo.bhash = 2877 tcp_hashinfo.bhash =
2879 alloc_large_system_hash("TCP bind", 2878 alloc_large_system_hash("TCP bind",
2880 sizeof(struct inet_bind_hashbucket), 2879 sizeof(struct inet_bind_hashbucket),
2881 tcp_hashinfo.ehash_size, 2880 tcp_hashinfo.ehash_mask + 1,
2882 (totalram_pages >= 128 * 1024) ? 2881 (totalram_pages >= 128 * 1024) ?
2883 13 : 15, 2882 13 : 15,
2884 0, 2883 0,
@@ -2933,8 +2932,8 @@ void __init tcp_init(void)
2933 sysctl_tcp_rmem[2] = max(87380, max_share); 2932 sysctl_tcp_rmem[2] = max(87380, max_share);
2934 2933
2935 printk(KERN_INFO "TCP: Hash tables configured " 2934 printk(KERN_INFO "TCP: Hash tables configured "
2936 "(established %d bind %d)\n", 2935 "(established %u bind %u)\n",
2937 tcp_hashinfo.ehash_size, tcp_hashinfo.bhash_size); 2936 tcp_hashinfo.ehash_mask + 1, tcp_hashinfo.bhash_size);
2938 2937
2939 tcp_register_congestion_control(&tcp_reno); 2938 tcp_register_congestion_control(&tcp_reno);
2940} 2939}