summaryrefslogtreecommitdiffstats
path: root/sys/nfsserver
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/nfsserver
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/nfsserver')
-rw-r--r--sys/nfsserver/nfs_srvsock.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/sys/nfsserver/nfs_srvsock.c b/sys/nfsserver/nfs_srvsock.c
index d372b92..fb29864 100644
--- a/sys/nfsserver/nfs_srvsock.c
+++ b/sys/nfsserver/nfs_srvsock.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_socket.c 8.3 (Berkeley) 1/12/94
- * $Id: nfs_socket.c,v 1.15 1996/02/13 18:16:28 wollman Exp $
+ * $Id: nfs_socket.c,v 1.16 1996/06/14 11:13:18 phk Exp $
*/
/*
@@ -1347,11 +1347,12 @@ nfs_timer(arg)
nmp->nm_sent < nmp->nm_cwnd) &&
(m = m_copym(rep->r_mreq, 0, M_COPYALL, M_DONTWAIT))){
if ((nmp->nm_flag & NFSMNT_NOCONN) == 0)
- error = (*so->so_proto->pr_usrreq)(so, PRU_SEND, m,
- (struct mbuf *)0, (struct mbuf *)0);
+ error = (*so->so_proto->pr_usrreqs->pru_send)
+ (so, 0, m, (struct mbuf *)0,
+ (struct mbuf *)0);
else
- error = (*so->so_proto->pr_usrreq)(so, PRU_SEND, m,
- nmp->nm_nam, (struct mbuf *)0);
+ error = (*so->so_proto->pr_usrreqs->pru_send)
+ (so, 0, m, nmp->nm_nam, (struct mbuf *)0);
if (error) {
if (NFSIGNORE_SOERROR(nmp->nm_soflags, error))
so->so_error = 0;
OpenPOWER on IntegriCloud