Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F144603672
D4446.1775693305.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
980 B
Referenced Files
None
Subscribers
None
D4446.1775693305.diff
View Options
Index: sys/dev/nvd/nvd.c
===================================================================
--- sys/dev/nvd/nvd.c
+++ sys/dev/nvd/nvd.c
@@ -279,7 +279,18 @@
disk->d_sectorsize = nvme_ns_get_sector_size(ns);
disk->d_mediasize = (off_t)nvme_ns_get_size(ns);
disk->d_delmaxsize = (off_t)nvme_ns_get_size(ns);
- disk->d_stripesize = nvme_ns_get_stripesize(ns);
+ /*
+ * Intel NVMe controllers have a slow path for I/Os that span a 128KB
+ * stripe boundary but ZFS limits ashift, which is derived from
+ * d_stripesize, to 13 (8KB) so we limit the stripesize reported to
+ * geom(8) to 4KB.
+ *
+ * This may result in a small number of additional I/Os to require
+ * splitting in nvme(4), however the NVMe I/O path is very efficient
+ * so these additional I/Os will cause very minimal (if any) difference
+ * in performance or CPU utilisation.
+ */
+ disk->d_stripesize = MIN(nvme_ns_get_stripesize(ns), 1<<12);
if (TAILQ_EMPTY(&disk_head))
disk->d_unit = 0;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Apr 9, 12:08 AM (8 h, 22 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28305132
Default Alt Text
D4446.1775693305.diff (980 B)
Attached To
Mode
D4446: Limit stripesize reported from nvd(4) for to geom(8) to 4K
Attached
Detach File
Event Timeline
Log In to Comment