Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Dec 2012 12:19:22 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r244625 - stable/8/sys/cddl/contrib/opensolaris/uts/common/fs/zfs
Message-ID:  <201212231219.qBNCJMfs091067@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Sun Dec 23 12:19:22 2012
New Revision: 244625
URL: http://svnweb.freebsd.org/changeset/base/244625

Log:
  MFC r242567: zfs_mount: drop vfs.zfs.rootpool.prefer_cached_config tunable

Modified:
  stable/8/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/cddl/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)

Modified: stable/8/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c
==============================================================================
--- stable/8/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c	Sun Dec 23 12:19:07 2012	(r244624)
+++ stable/8/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c	Sun Dec 23 12:19:22 2012	(r244625)
@@ -1652,24 +1652,12 @@ zfs_mount(vfs_t *vfsp)
 	if ((vfsp->vfs_flag & MNT_ROOTFS) != 0 &&
 	    (vfsp->vfs_flag & MNT_UPDATE) == 0) {
 		char pname[MAXNAMELEN];
-		spa_t *spa;
-		int prefer_cache;
 
 		error = getpoolname(osname, pname);
+		if (error == 0)
+			error = spa_import_rootpool(pname);
 		if (error)
 			goto out;
-
-		prefer_cache = 1;
-		TUNABLE_INT_FETCH("vfs.zfs.rootpool.prefer_cached_config",
-		    &prefer_cache);
-		mutex_enter(&spa_namespace_lock);
-		spa = spa_lookup(pname);
-		mutex_exit(&spa_namespace_lock);
-		if (!prefer_cache || spa == NULL) {
-			error = spa_import_rootpool(pname);
-			if (error)
-				goto out;
-		}
 	}
 	DROP_GIANT();
 	error = zfs_domount(vfsp, osname);



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