diff options
| author | Warner Losh <imp@FreeBSD.org> | 2022-04-15 20:40:57 +0000 |
|---|---|---|
| committer | Warner Losh <imp@FreeBSD.org> | 2022-04-15 20:46:18 +0000 |
| commit | a7218e7a6b05557c9ce60f8db33c06c97da72641 (patch) | |
| tree | 0491fc8eb44995b7ff652e18f65767c82cf74087 /sys/dev | |
| parent | e66c1b51850cbe5e2b02a13131dfce83a0c9a121 (diff) | |
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/nvme/nvme_ns.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/dev/nvme/nvme_ns.c b/sys/dev/nvme/nvme_ns.c index ba6960e476f8..da700ae9f59f 100644 --- a/sys/dev/nvme/nvme_ns.c +++ b/sys/dev/nvme/nvme_ns.c @@ -567,14 +567,16 @@ nvme_ns_construct(struct nvme_namespace *ns, uint32_t id, } /* - * Older Intel devices advertise in vendor specific space an alignment - * that improves performance. If present use for the stripe size. NVMe - * 1.3 standardized this as NOIOB, and newer Intel drives use that. + * Older Intel devices (like the PC35xxx and P45xx series) advertise in + * vendor specific space an alignment that improves performance. If + * present use for the stripe size. NVMe 1.3 standardized this as + * NOIOB, and newer Intel drives use that. */ if ((ctrlr->quirks & QUIRK_INTEL_ALIGNMENT) != 0) { if (ctrlr->cdata.vs[3] != 0) ns->boundary = - (1 << ctrlr->cdata.vs[3]) * ctrlr->min_page_size; + 1 << (ctrlr->cdata.vs[3] + NVME_MPS_SHIFT + + NVME_CAP_HI_MPSMIN(ctrlr->cap_hi)); else ns->boundary = 0; } else { |
