Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 20 Oct 2009 15:06:18 +0000 (UTC)
From:      Jaakko Heinonen <jh@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r198291 - head/sys/fs/nfsclient
Message-ID:  <200910201506.n9KF6IvV070423@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jh
Date: Tue Oct 20 15:06:18 2009
New Revision: 198291
URL: http://svn.freebsd.org/changeset/base/198291

Log:
  Unloading of the nfscl module is unsupported because newnfslock doesn't
  support unloading. It's not trivial to implement newnfslock unloading so
  for now just admit that unloading is unsupported and refuse to attempt
  unload in all nfscl module event handlers.
  
  Reviewed by:	rmacklem
  Approved by:	trasz (mentor)

Modified:
  head/sys/fs/nfsclient/nfs_clport.c
  head/sys/fs/nfsclient/nfs_clsubs.c

Modified: head/sys/fs/nfsclient/nfs_clport.c
==============================================================================
--- head/sys/fs/nfsclient/nfs_clport.c	Tue Oct 20 15:01:46 2009	(r198290)
+++ head/sys/fs/nfsclient/nfs_clport.c	Tue Oct 20 15:06:18 2009	(r198291)
@@ -1243,6 +1243,10 @@ nfscl_modevent(module_t mod, int type, v
 			break;
 		}
 
+		/*
+		 * XXX: Unloading of nfscl module is unsupported.
+		 */
+#if 0
 		ncl_call_invalcaches = NULL;
 		nfsd_call_nfscl = NULL;
 		/* and get rid of the mutexes */
@@ -1250,6 +1254,9 @@ nfscl_modevent(module_t mod, int type, v
 		mtx_destroy(&ncl_iod_mutex);
 		loaded = 0;
 		break;
+#else
+		/* FALLTHROUGH */
+#endif
 	default:
 		error = EOPNOTSUPP;
 		break;

Modified: head/sys/fs/nfsclient/nfs_clsubs.c
==============================================================================
--- head/sys/fs/nfsclient/nfs_clsubs.c	Tue Oct 20 15:01:46 2009	(r198290)
+++ head/sys/fs/nfsclient/nfs_clsubs.c	Tue Oct 20 15:06:18 2009	(r198291)
@@ -87,6 +87,10 @@ extern struct nfsstats newnfsstats;
 int
 ncl_uninit(struct vfsconf *vfsp)
 {
+	/*
+	 * XXX: Unloading of nfscl module is unsupported.
+	 */
+#if 0
 	int i;
 
 	/*
@@ -104,6 +108,9 @@ ncl_uninit(struct vfsconf *vfsp)
 	mtx_unlock(&ncl_iod_mutex);
 	ncl_nhuninit();
 	return (0);
+#else
+	return (EOPNOTSUPP);
+#endif
 }
 
 void 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200910201506.n9KF6IvV070423>