Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 6 Oct 2019 22:17:29 +0000 (UTC)
From:      Mateusz Guzik <mjg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r353154 - head/sys/fs/nfsclient
Message-ID:  <201910062217.x96MHTkC085971@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mjg
Date: Sun Oct  6 22:17:29 2019
New Revision: 353154
URL: https://svnweb.freebsd.org/changeset/base/353154

Log:
  nfsclient: add root vnode caching
  
  See r353150.
  
  Sponsored by:   The FreeBSD Foundation
  Differential Revision:  https://reviews.freebsd.org/D21646

Modified:
  head/sys/fs/nfsclient/nfs_clvfsops.c

Modified: head/sys/fs/nfsclient/nfs_clvfsops.c
==============================================================================
--- head/sys/fs/nfsclient/nfs_clvfsops.c	Sun Oct  6 22:17:11 2019	(r353153)
+++ head/sys/fs/nfsclient/nfs_clvfsops.c	Sun Oct  6 22:17:29 2019	(r353154)
@@ -136,7 +136,8 @@ static struct vfsops nfs_vfsops = {
 	.vfs_init =		ncl_init,
 	.vfs_mount =		nfs_mount,
 	.vfs_cmount =		nfs_cmount,
-	.vfs_root =		nfs_root,
+	.vfs_root =		vfs_cache_root,
+	.vfs_cachedroot =	nfs_root,
 	.vfs_statfs =		nfs_statfs,
 	.vfs_sync =		nfs_sync,
 	.vfs_uninit =		ncl_uninit,
@@ -1626,6 +1627,7 @@ mountnfs(struct nfs_args *argp, struct mount *mp, stru
 		 * Lose the lock but keep the ref.
 		 */
 		NFSVOPUNLOCK(*vpp, 0);
+		vfs_cache_root_set(mp, *vpp);
 		return (0);
 	}
 	error = EIO;



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