Page MenuHomeFreeBSD

nvme: Move opcode and status code tables from base CAM to nvme_util.c
ClosedPublic

Authored by jhb on Jun 4 2025, 4:32 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Sep 6, 3:19 PM
Unknown Object (File)
Sat, Aug 22, 11:33 AM
Unknown Object (File)
Fri, Aug 21, 8:31 PM
Unknown Object (File)
Aug 17 2026, 10:49 AM
Unknown Object (File)
Aug 13 2026, 1:44 AM
Unknown Object (File)
Aug 11 2026, 11:20 PM
Unknown Object (File)
Aug 10 2026, 7:46 AM
Unknown Object (File)
Aug 9 2026, 6:37 PM
Subscribers

Details

Summary

This makes it possible to share these tables with the nvme(4) driver
in custom kernels that do not include any CAM support, only nvd(4).

Sponsored by: Chelsio Communications

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jhb requested review of this revision.Jun 4 2025, 4:32 PM

Include nvme_util.c in CAM kernels without nvme

imp added inline comments.
sys/dev/nvme/nvme_util.c
40

Still a dupe?

This revision is now accepted and ready to land.Jun 4 2025, 4:39 PM

cam.ko already includes nvme_util.c. (Which means that today it is present in both cam.ko and nvme.ko. Not sure how that works out if you try to kldload both of them in a MINIMAL kernel. I would probably vote for taking it out of nvme.ko since nvme.ko already depends on cam.ko unconditionally.)

sys/dev/nvme/nvme_util.c
40

I trim this comment in the followup change that removes the tables from nvme_qpair.c.