summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in_proto.c
diff options
context:
space:
mode:
authorwollman <wollman@FreeBSD.org>1996-07-11 16:32:50 +0000
committerwollman <wollman@FreeBSD.org>1996-07-11 16:32:50 +0000
commit36ac1a02631aaa05aa36416979316960c69d3f06 (patch)
tree8c5d769659a79218ab7f5a25af062167216d07a1 /sys/netinet/in_proto.c
parentd2bef1a0e554bc9afc083cd2a8a85c8e04c4fd2c (diff)
downloadFreeBSD-src-36ac1a02631aaa05aa36416979316960c69d3f06.zip
FreeBSD-src-36ac1a02631aaa05aa36416979316960c69d3f06.tar.gz
Modify the kernel to use the new pr_usrreqs interface rather than the old
pr_usrreq mechanism which was poorly designed and error-prone. This commit renames pr_usrreq to pr_ousrreq so that old code which depended on it would break in an obvious manner. This commit also implements the new interface for TCP, although the old function is left as an example (#ifdef'ed out). This commit ALSO fixes a longstanding bug in the TCP timer processing (introduced by davidg on 1995/04/12) which caused timer processing on a TCB to always stop after a single timer had expired (because it misinterpreted the return value from tcp_usrreq() to indicate that the TCB had been deleted). Finally, some code related to polling has been deleted from if.c because it is not relevant t -current and doesn't look at all like my current code.
Diffstat (limited to 'sys/netinet/in_proto.c')
-rw-r--r--sys/netinet/in_proto.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/netinet/in_proto.c b/sys/netinet/in_proto.c
index fef71ac..f97c803 100644
--- a/sys/netinet/in_proto.c
+++ b/sys/netinet/in_proto.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_proto.c 8.2 (Berkeley) 2/9/95
- * $Id: in_proto.c,v 1.31 1996/06/20 17:52:32 fenner Exp $
+ * $Id: in_proto.c,v 1.32 1996/07/10 19:44:21 julian Exp $
*/
#include <sys/param.h>
@@ -105,8 +105,9 @@ struct protosw inetsw[] = {
{ SOCK_STREAM, &inetdomain, IPPROTO_TCP,
PR_CONNREQUIRED|PR_IMPLOPCL|PR_WANTRCVD,
tcp_input, 0, tcp_ctlinput, tcp_ctloutput,
- tcp_usrreq,
- tcp_init, tcp_fasttimo, tcp_slowtimo, tcp_drain
+ 0,
+ tcp_init, tcp_fasttimo, tcp_slowtimo, tcp_drain,
+ &tcp_usrreqs
},
{ SOCK_RAW, &inetdomain, IPPROTO_RAW, PR_ATOMIC|PR_ADDR,
rip_input, 0, 0, rip_ctloutput,
OpenPOWER on IntegriCloud