numam-spdk/PORTING.md
Ben Walker 6b1e4e732d Drop libpciaccess and switch to DPDK PCI
This patch also drops support for automatically unbinding
devices from the kernel - run scripts/setup.sh first.

Our generic pci interface is now hidden behind include/spdk/pci.h
and implemented in lib/util/pci.c. We no longer wrap the calls
in nvme_impl.h or ioat_impl.h. The implementation now only uses
DPDK and the libpciaccess dependency has been removed. If using
a version of DPDK earlier than 16.07, enumerating devices
by class code isn't available and only Intel SSDs will be
discovered. DPDK 16.07 adds enumeration by class code and all
NVMe devices will be correctly discovered.

Change-Id: I0e8bac36b5ca57df604a2b310c47342c67dc9f3c
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
2016-10-04 15:59:00 -07:00

895 B

SPDK Porting Guide

SPDK is ported to new environments by implementing the nvme_impl interface. The nvme_impl interface provides APIs for the driver to allocate physically contiguous and pinned memory, perform PCI operations (config cycles and mapping BARs), virtual to physical address translation and allocating per I/O data structures.

SPDK includes a default implementation of the nvme_impl API based on the Data Plane Development Kit (DPDK). This DPDK implementation can be found in lib/nvme/nvme_impl.h. DPDK is currently supported on Linux and FreeBSD only.

Users who want to use SPDK on other operating system, or in userspace driver frameworks other than DPDK, will need to implement a new version of nvme_impl.h. The new nvme_impl.h can be integrated into the SPDK build by updating the following line in CONFIG:

CONFIG_NVME_IMPL=nvme_impl.h