FreeBSD#
System Configuration#
FreeBSD is one of several supported platforms. xNVMe is likely to work on multiple versions of FreeBSD, however to ensure compatibility we recommend using a version listed in the Toolchain section.
Device Identification#
FreeBSD exposes NVMe devices as files using the following naming schemes:
/dev/nvme{ctrlr_id}NVMe Controller device node
/dev/nvme{ctrlr_id}ns{ns_id}NVMe Namespace as device node
/dev/nda{num}NVMe Namespace as storage device node
/dev/nvd{num}NVMe Namespace as disk drive
For details see the man-pages for nvme, nda, nvd, pci, disk,
and nvmecontrol.
Backend Configs#
The FreeBSD platform provides the following backend configs. Some of these use cross-platform implementations from the Common Backend Implementations (CBI). For these, links point to descriptions in the CBI section. For the FreeBSD-specific interfaces, descriptions are available in the corresponding subsections.
Memory Allocators
posix, Use libcmalloc()/free()withsysconf()for alignment, add link to CBI
Asynchronous Interfaces
kqueue, Use kqueue based aio for Asynchronous I/Oposix, add link to CBIemu, add link to CBIthrpool, add link to CBInil, add link to CBI
Synchronous Interfaces
nvme, Use FreeBSD NVMe Driver ioctl() for synchronous I/Opsync, Use pread()/write() for synchronous I/O
Admin Interfaces
nvme, Use FreeBSD NVMe Driver ioctl() for admin commands
Device Interfaces
freebsd, Use FreeBSD file/dev handles and enumerate NVMe devices