]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
nvme_ctrlr_enable: Remove unnecessary 5ms delays
authorWarner Losh <imp@FreeBSD.org>
Fri, 1 Oct 2021 16:47:27 +0000 (10:47 -0600)
committerWarner Losh <imp@FreeBSD.org>
Fri, 1 Oct 2021 16:56:10 +0000 (10:56 -0600)
commitd5fca1dc1d7de15695b65374d6457abd29a747ee
treec4e4ec23f519c235e852c75b9f8ac9efb57ab79b
parent35e4527e88d3843cccf2f15a32b1fa041a01d693
nvme_ctrlr_enable: Remove unnecessary 5ms delays

Remove the 5ms delays after writing the administrative queue
registers. These delays are from the very earliest days of the driver
(they are in the first commit) and were most likely vestiges of the
Chatham NVMe prototype card that was used to create this driver. Many of
the workarounds necessary for it aren't necessary for standards
compliant cards. The original driver had other areas marked for Chatham,
but these were not. They are unneeded. There's three lines of supporting
evidence.

First, the NVMe standards make no mention of a delay time after these
registers are written. Second, the Linux driver doesn't have them, even
as an option. Third, all my nvme cards work w/o them.

To be safe, add a write barrier between setting up the admin queue and
enabling the controller.

Sponsored by: Netflix
Reviewed by: mav
Differential Revision: https://reviews.freebsd.org/D32247
sys/dev/nvme/nvme_ctrlr.c