Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 14 Jun 2018 15:02:28 +0000 (UTC)
From:      Alexander Motin <mav@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r335143 - stable/11/sys/dev/nvme
Message-ID:  <201806141502.w5EF2Stc025627@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mav
Date: Thu Jun 14 15:02:27 2018
New Revision: 335143
URL: https://svnweb.freebsd.org/changeset/base/335143

Log:
  MFC r330953 (by imp): Don't make the namespace devices eternal.
  
  We'll need to delete namespaces soon, so go ahead and stop making
  these devices eternal. It doesn't help much, and will be getting in
  the way soon.

Modified:
  stable/11/sys/dev/nvme/nvme_ns.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/nvme/nvme_ns.c
==============================================================================
--- stable/11/sys/dev/nvme/nvme_ns.c	Thu Jun 14 14:58:51 2018	(r335142)
+++ stable/11/sys/dev/nvme/nvme_ns.c	Thu Jun 14 15:02:27 2018	(r335143)
@@ -562,21 +562,9 @@ nvme_ns_construct(struct nvme_namespace *ns, uint32_t 
 	 */
 	unit = device_get_unit(ctrlr->dev) * NVME_MAX_NAMESPACES + ns->id - 1;
 
-/*
- * MAKEDEV_ETERNAL was added in r210923, for cdevs that will never
- *  be destroyed.  This avoids refcounting on the cdev object.
- *  That should be OK case here, as long as we're not supporting PCIe
- *  surprise removal nor namespace deletion.
- */
-#ifdef MAKEDEV_ETERNAL_KLD
-	ns->cdev = make_dev_credf(MAKEDEV_ETERNAL_KLD, &nvme_ns_cdevsw, unit,
-	    NULL, UID_ROOT, GID_WHEEL, 0600, "nvme%dns%d",
-	    device_get_unit(ctrlr->dev), ns->id);
-#else
 	ns->cdev = make_dev_credf(0, &nvme_ns_cdevsw, unit,
 	    NULL, UID_ROOT, GID_WHEEL, 0600, "nvme%dns%d",
 	    device_get_unit(ctrlr->dev), ns->id);
-#endif
 #ifdef NVME_UNMAPPED_BIO_SUPPORT
 	ns->cdev->si_flags |= SI_UNMAPPED;
 #endif



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