nvmf:Add RNIC HBA userspace library for FreeBSD

Change-Id: I7d929e7520007f29511299442f791038f7a4ce1d
Signed-off-by: John Meneghini <johnm@netapp.com>
Reviewed-on: https://review.gerrithub.io/409539
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
Sai Tallamraju 2018-04-25 16:00:44 -04:00 committed by Jim Harris
parent 142221987e
commit 27a2d1d04d
2 changed files with 31 additions and 0 deletions

View File

@ -0,0 +1,5 @@
# Compiling perf on FreeBSD
To use perf test on FreeBSD over NVMe-oF, explicitly link userspace library of HBA. For example, on a setup with Mellanox HBA,
LIBS += -lmlx5

View File

@ -125,6 +125,32 @@ LIBS += -L$(CONFIG_VPP_DIR)/lib64
COMMON_CFLAGS += -I$(CONFIG_VPP_DIR)/include
endif
#Attach only if FreeBSD and RDMA is specified with configure
ifeq ($(OS),FreeBSD)
ifeq ($(CONFIG_RDMA),y)
# RDMA Userspace Verbs Library
ifneq ("$(wildcard /usr/lib/libibverbs.*)","")
LIBS += -libverbs
endif
# RDMA Connection Manager Library
ifneq ("$(wildcard /usr/lib/librdmacm.*)","")
LIBS += -lrdmacm
endif
# Mellanox - MLX4 HBA Userspace Library
ifneq ("$(wildcard /usr/lib/libmlx4.*)","")
LIBS += -lmlx4
endif
# Mellanox - MLX5 HBA Userspace Library
ifneq ("$(wildcard /usr/lib/libmlx5.*)","")
LIBS += -lmlx5
endif
# Chelsio HBA Userspace Library
ifneq ("$(wildcard /usr/lib/libcxgb4.*)","")
LIBS += -lcxgb4
endif
endif
endif
ifeq ($(CONFIG_DEBUG), y)
COMMON_CFLAGS += -DDEBUG -O0 -fno-omit-frame-pointer
else