Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Feb 2019 03:52:44 +0000 (UTC)
From:      Patrick Kelsey <pkelsey@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r344227 - head/stand/i386/zfsboot
Message-ID:  <201902170352.x1H3qiPo041663@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pkelsey
Date: Sun Feb 17 03:52:44 2019
New Revision: 344227
URL: https://svnweb.freebsd.org/changeset/base/344227

Log:
  Remove whole-disk vdev support from zfsboot
  
  This is consistent with the removal of whole-disk vdev support from
  libsa/zfs/zfs.c in r342151, and is part way to having the LBAs read
  during probe be fully constrained by partition tables when present.
  
  Reviewed by:	tsoome
  MFC after:	3 months
  Differential Revision:	https://reviews.freebsd.org/D19142

Modified:
  head/stand/i386/zfsboot/zfsboot.c

Modified: head/stand/i386/zfsboot/zfsboot.c
==============================================================================
--- head/stand/i386/zfsboot/zfsboot.c	Sun Feb 17 03:35:15 2019	(r344226)
+++ head/stand/i386/zfsboot/zfsboot.c	Sun Feb 17 03:52:44 2019	(r344227)
@@ -545,32 +545,19 @@ probe_drive(struct zfsdsk *zdsk)
     char *sec;
     unsigned i;
 
-    /*
-     * If we find a vdev on the whole disk, stop here.
-     */
-    if (vdev_probe(vdev_read2, zdsk, NULL) == 0)
-	return;
-
 #ifdef LOADER_GELI_SUPPORT
     /*
-     * Taste the disk, if it is GELI encrypted, decrypt it and check to see if
-     * it is a usable vdev then. Otherwise dig
-     * out the partition table and probe each slice/partition
-     * in turn for a vdev or GELI encrypted vdev.
+     * Taste the disk, if it is GELI encrypted, decrypt it then dig out the
+     * partition table and probe each slice/partition in turn for a vdev or
+     * GELI encrypted vdev.
      */
     elba = drvsize_ext(zdsk);
     if (elba > 0) {
 	elba--;
     }
     zdsk->gdev = geli_taste(vdev_read, zdsk, elba, "disk%u:0:");
-    if (zdsk->gdev != NULL) {
-	if (geli_havekey(zdsk->gdev) == 0 || 
-	    geli_passphrase(zdsk->gdev, gelipw) == 0) {
-	    if (vdev_probe(vdev_read2, zdsk, NULL) == 0) {
-		return;
-	    }
-	}
-    }
+    if ((zdsk->gdev != NULL) && (geli_havekey(zdsk->gdev) == 0))
+	    geli_passphrase(zdsk->gdev, gelipw);
 #endif /* LOADER_GELI_SUPPORT */
 
     sec = dmadat->secbuf;



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