aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/sock.c
diff options
context:
space:
mode:
authorBrian Haley <brian.haley@hp.com>2006-09-22 17:15:41 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2006-09-22 17:55:03 -0400
commitab32ea5d8a760e7dd4339634e95d7be24ee5b842 (patch)
tree8460a66c529fe03f926848326d9b6aa874e19514 /net/core/sock.c
parent56fc85ac961e2c20dcb5ef07e2628b3f93de2e49 (diff)
[NET/IPV4/IPV6]: Change some sysctl variables to __read_mostly
Change net/core, ipv4 and ipv6 sysctl variables to __read_mostly. Couldn't actually measure any performance increase while testing (.3% I consider noise), but seems like the right thing to do. Signed-off-by: Brian Haley <brian.haley@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/sock.c')
-rw-r--r--net/core/sock.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/net/core/sock.c b/net/core/sock.c
index b67d868649cd..cfaf09039b02 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -187,13 +187,13 @@ static struct lock_class_key af_callback_keys[AF_MAX];
187#define SK_RMEM_MAX (_SK_MEM_OVERHEAD * _SK_MEM_PACKETS) 187#define SK_RMEM_MAX (_SK_MEM_OVERHEAD * _SK_MEM_PACKETS)
188 188
189/* Run time adjustable parameters. */ 189/* Run time adjustable parameters. */
190__u32 sysctl_wmem_max = SK_WMEM_MAX; 190__u32 sysctl_wmem_max __read_mostly = SK_WMEM_MAX;
191__u32 sysctl_rmem_max = SK_RMEM_MAX; 191__u32 sysctl_rmem_max __read_mostly = SK_RMEM_MAX;
192__u32 sysctl_wmem_default = SK_WMEM_MAX; 192__u32 sysctl_wmem_default __read_mostly = SK_WMEM_MAX;
193__u32 sysctl_rmem_default = SK_RMEM_MAX; 193__u32 sysctl_rmem_default __read_mostly = SK_RMEM_MAX;
194 194
195/* Maximal space eaten by iovec or ancilliary data plus some space */ 195/* Maximal space eaten by iovec or ancilliary data plus some space */
196int sysctl_optmem_max = sizeof(unsigned long)*(2*UIO_MAXIOV + 512); 196int sysctl_optmem_max __read_mostly = sizeof(unsigned long)*(2*UIO_MAXIOV+512);
197 197
198static int sock_set_timeout(long *timeo_p, char __user *optval, int optlen) 198static int sock_set_timeout(long *timeo_p, char __user *optval, int optlen)
199{ 199{