svn commit: r325007 - head/sys/geom/mountver

Edward Tomasz Napierala trasz at FreeBSD.org
Thu Oct 26 09:29:36 UTC 2017


Author: trasz
Date: Thu Oct 26 09:29:35 2017
New Revision: 325007
URL: https://svnweb.freebsd.org/changeset/base/325007

Log:
  Make gmountver(8) use G_PF_ACCEPT_UNMAPPED.
  
  MFC after:	2 weeks

Modified:
  head/sys/geom/mountver/g_mountver.c

Modified: head/sys/geom/mountver/g_mountver.c
==============================================================================
--- head/sys/geom/mountver/g_mountver.c	Thu Oct 26 03:38:40 2017	(r325006)
+++ head/sys/geom/mountver/g_mountver.c	Thu Oct 26 09:29:35 2017	(r325007)
@@ -271,6 +271,14 @@ g_mountver_create(struct gctl_req *req, struct g_class
 	newpp->mediasize = pp->mediasize;
 	newpp->sectorsize = pp->sectorsize;
 
+	if ((pp->flags & G_PF_ACCEPT_UNMAPPED) != 0) {
+		G_MOUNTVER_DEBUG(0, "Unmapped supported for %s.", gp->name);
+		newpp->flags |= G_PF_ACCEPT_UNMAPPED;
+	} else {
+		G_MOUNTVER_DEBUG(0, "Unmapped unsupported for %s.", gp->name);
+		newpp->flags &= ~G_PF_ACCEPT_UNMAPPED;
+	}
+
 	cp = g_new_consumer(gp);
 	error = g_attach(cp, pp);
 	if (error != 0) {


More information about the svn-src-head mailing list