patch-2.1.91 linux/net/ipv4/route.c
Next file: linux/net/ipv4/sysctl_net_ipv4.c
Previous file: linux/net/ipv4/proc.c
Back to the patch index
Back to the overall index
- Lines: 40
- Date:
Mon Mar 23 16:48:25 1998
- Orig file:
v2.1.90/linux/net/ipv4/route.c
- Orig date:
Tue Mar 17 22:18:16 1998
diff -u --recursive --new-file v2.1.90/linux/net/ipv4/route.c linux/net/ipv4/route.c
@@ -5,7 +5,7 @@
*
* ROUTE - implementation of the IP router.
*
- * Version: $Id: route.c,v 1.41 1998/03/08 20:52:38 davem Exp $
+ * Version: $Id: route.c,v 1.42 1998/03/20 09:12:09 davem Exp $
*
* Authors: Ross Biro, <bir7@leland.Stanford.Edu>
* Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
@@ -104,6 +104,7 @@
int ip_rt_redirect_silence = ((HZ/50) << (9+1));
int ip_rt_error_cost = HZ;
int ip_rt_error_burst = 5*HZ;
+int ip_rt_gc_elasticity = 8;
static unsigned long rt_deadline = 0;
@@ -398,10 +399,10 @@
last_gc = now;
if (atomic_read(&ipv4_dst_ops.entries) < ipv4_dst_ops.gc_thresh)
- expire = ip_rt_gc_timeout;
+ expire = ip_rt_gc_timeout>>1;
out:
- expire >>= 1;
+ expire -= expire>>ip_rt_gc_elasticity;
end_bh_atomic();
return (atomic_read(&ipv4_dst_ops.entries) > ip_rt_max_size);
}
@@ -1739,6 +1740,9 @@
&proc_dointvec},
{NET_IPV4_ROUTE_ERROR_BURST, "error_burst",
&ip_rt_error_burst, sizeof(int), 0644, NULL,
+ &proc_dointvec},
+ {NET_IPV4_ROUTE_GC_ELASTICITY, "gc_elasticity",
+ &ip_rt_gc_elasticity, sizeof(int), 0644, NULL,
&proc_dointvec},
{0}
};
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov