Bug 233960

Summary: Add Volume Management Device (VMD) stub driver
Product: Base System Reporter: David Fugate <dave.fugate>
Component: kernAssignee: Doug Ambrisko <ambrisko>
Status: Closed FIXED    
Severity: Affects Many People CC: ambrisko, cem, emaste, imp
Priority: --- Keywords: patch
Version: CURRENT   
Hardware: amd64   
OS: Any   
Attachments:
Description Flags
VMD Driver Patch none

Description David Fugate 2018-12-12 17:01:51 UTC
Created attachment 200058 [details]
VMD Driver Patch

At a high-level, "IntelĀ® VMD enables hot swap replacement of NVMe* SSDs from the PCIe* bus without shutting down the system while standardized LED management helps provide quick identification of SSD status."  

This is realized through the addition of a VMD controller on the PCIe bus of high-end systems (e.g., Xeon) which "hides" 1 to N PCIe ports underneath it.  As you might imagine, this implies the need for a VMD driver which either delegates incoming NVMe requests to the appropriate drivers (e.g., NVMe, hot-plug, etc.) or a VMD driver which incorporates the NVMe, hot-plug, etc. functionality all on its own.

FreeBSD is missing either such type of VMD driver today, and consequently end-users like Netflix are getting the mistaken impression FreeBSD doesn't have a driver for their invisible NVMe devices or the NVMe devices are broken...

Attached to this bug report is a patch adding a VMD stub driver informing the end-user they should disable the VMD feature in their BIOS.  This stub driver is a stop-gap measure to eventually be replaced with a full-fledged VMD driver (I work for the NVMe/VMD OSS driver team at Intel).
Comment 1 David Fugate 2018-12-12 17:37:40 UTC
BTW, this patch was tested in a system with VMD enabled:
root@midnight-freebsd:/usr/src # dmesg | grep vmd
vmd0: Unsupported Volume Management Device (VMD) controller enabled.
Comment 2 Doug Ambrisko freebsd_committer freebsd_triage 2019-03-18 23:47:59 UTC
Hi David,

I have a hacked up VMD driver limping along.  I'd like to co-ordinate work on this.  It's not full feature but I can do I/Os to SSD's in VMD mode and with VROC enabled.  GRAID should be taught how to read the EFI variable from VROC
and get RAID 5 write support etc.
Comment 3 Doug Ambrisko freebsd_committer freebsd_triage 2019-10-11 02:29:24 UTC
Checked in driver r353380.