summaryrefslogtreecommitdiffstats
path: root/sys/nfsclient/nfs_socket.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1998-05-31 19:49:31 +0000
committerpeter <peter@FreeBSD.org>1998-05-31 19:49:31 +0000
commit401c250cc40de5fcfc5f53856a8194793ba32667 (patch)
tree77292b0fb6150895d044dedafa84184c95243d2e /sys/nfsclient/nfs_socket.c
parent5080277e0ee6d3017bdd8ac4e416ccef13a15697 (diff)
downloadFreeBSD-src-401c250cc40de5fcfc5f53856a8194793ba32667.zip
FreeBSD-src-401c250cc40de5fcfc5f53856a8194793ba32667.tar.gz
Support 'mount -u' remounts. This may require disconnecting and rebinding
the socket. Certain mode changes are not allowed. Obtained from: NetBSD
Diffstat (limited to 'sys/nfsclient/nfs_socket.c')
-rw-r--r--sys/nfsclient/nfs_socket.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/sys/nfsclient/nfs_socket.c b/sys/nfsclient/nfs_socket.c
index 45f2b61..8fcefeb 100644
--- a/sys/nfsclient/nfs_socket.c
+++ b/sys/nfsclient/nfs_socket.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_socket.c 8.5 (Berkeley) 3/30/95
- * $Id: nfs_socket.c,v 1.37 1998/05/31 18:06:07 peter Exp $
+ * $Id: nfs_socket.c,v 1.38 1998/05/31 18:08:09 peter Exp $
*/
/*
@@ -371,6 +371,19 @@ nfs_disconnect(nmp)
}
}
+void
+nfs_safedisconnect(nmp)
+ struct nfsmount *nmp;
+{
+ struct nfsreq dummyreq;
+
+ bzero(&dummyreq, sizeof(dummyreq));
+ dummyreq.r_nmp = nmp;
+ nfs_rcvlock(&dummyreq);
+ nfs_disconnect(nmp);
+ nfs_rcvunlock(&nmp->nm_flag, &nmp->nm_state);
+}
+
/*
* This is the nfs send routine. For connection based socket types, it
* must be called with an nfs_sndlock() on the socket.
OpenPOWER on IntegriCloud