diff options
author | jlemon <jlemon@FreeBSD.org> | 2003-03-08 22:06:20 +0000 |
---|---|---|
committer | jlemon <jlemon@FreeBSD.org> | 2003-03-08 22:06:20 +0000 |
commit | 03b8ace4891ef0ac6e1d27e79b9464022ed5fba0 (patch) | |
tree | 86b7ff103cc19bffc08502fceb82fff6fc3c8d83 /sys/netinet/tcp_var.h | |
parent | 3cab7a88ab3bf9db32f46801047c9350030d5e77 (diff) | |
download | FreeBSD-src-03b8ace4891ef0ac6e1d27e79b9464022ed5fba0.zip FreeBSD-src-03b8ace4891ef0ac6e1d27e79b9464022ed5fba0.tar.gz |
Remove a panic(); if the zone allocator can't provide more timewait
structures, reuse the oldest one. Also move the expiry timer from
a per-structure callout to the tcp slow timer.
Sponsored by: DARPA, NAI Labs
Diffstat (limited to 'sys/netinet/tcp_var.h')
-rw-r--r-- | sys/netinet/tcp_var.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h index e4a07f8..18780d7 100644 --- a/sys/netinet/tcp_var.h +++ b/sys/netinet/tcp_var.h @@ -247,7 +247,8 @@ struct tcptw { struct ucred *tw_cred; /* user credentials */ u_long t_recent; u_long t_starttime; - struct callout *tt_2msl; /* 2*msl TIME_WAIT timer */ + int tw_time; + LIST_ENTRY(tcptw) tw_2msl; }; /* @@ -464,7 +465,8 @@ void tcp_canceltimers(struct tcpcb *); struct tcpcb * tcp_close(struct tcpcb *); void tcp_twstart(struct tcpcb *); -void tcp_twclose(struct tcptw *); +struct tcptw * + tcp_twclose(struct tcptw *_tw, int _reuse); void tcp_ctlinput(int, struct sockaddr *, void *); int tcp_ctloutput(struct socket *, struct sockopt *); struct tcpcb * |