Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F168206821
D34869.id104845.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
787 B
Referenced Files
None
Subscribers
None
D34869.id104845.diff
View Options
Index: sys/dev/nvme/nvme_ctrlr.c
===================================================================
--- sys/dev/nvme/nvme_ctrlr.c
+++ sys/dev/nvme/nvme_ctrlr.c
@@ -388,8 +388,12 @@
cc |= 6 << NVME_CC_REG_IOSQES_SHIFT; /* SQ entry size == 64 == 2^6 */
cc |= 4 << NVME_CC_REG_IOCQES_SHIFT; /* CQ entry size == 16 == 2^4 */
- /* This evaluates to 0, which is according to spec. */
- cc |= (PAGE_SHIFT - NVME_BASE_SHIFT) << NVME_CC_REG_MPS_SHIFT;
+ /*
+ * Use the smallest page size because we set everything else relative to
+ * this both this field and the MPSMIN in cap_hi have the same bias of
+ * 12 so no adjustment here is needed.
+ */
+ cc |= ctrlr->mps << NVME_CC_REG_MPS_SHIFT;
nvme_ctrlr_barrier(ctrlr, BUS_SPACE_BARRIER_WRITE);
nvme_mmio_write_4(ctrlr, cc, cc);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Aug 27, 9:41 PM (12 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37419379
Default Alt Text
D34869.id104845.diff (787 B)
Attached To
Mode
D34869: nvme: Use saved mps when initializing drive
Attached
Detach File
Event Timeline
Log In to Comment