svn commit: r368630 - stable/12/sys/dev/nvme

Michal Meloun mmel at FreeBSD.org
Mon Dec 14 10:16:59 UTC 2020


Author: mmel
Date: Mon Dec 14 10:16:59 2020
New Revision: 368630
URL: https://svnweb.freebsd.org/changeset/base/368630

Log:
  MFC r367955:
  
    Ensure that the buffer is in nvme_single_map() mapped to single segment.
    Not a functional change.

Modified:
  stable/12/sys/dev/nvme/nvme_private.h
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/dev/nvme/nvme_private.h
==============================================================================
--- stable/12/sys/dev/nvme/nvme_private.h	Mon Dec 14 10:14:32 2020	(r368629)
+++ stable/12/sys/dev/nvme/nvme_private.h	Mon Dec 14 10:16:59 2020	(r368630)
@@ -477,6 +477,7 @@ nvme_single_map(void *arg, bus_dma_segment_t *seg, int
 {
 	uint64_t *bus_addr = (uint64_t *)arg;
 
+	KASSERT(nseg == 1, ("number of segments (%d) is not 1", nseg));
 	if (error != 0)
 		printf("nvme_single_map err %d\n", error);
 	*bus_addr = seg[0].ds_addr;


More information about the svn-src-stable mailing list