Commit c1ce8db0 authored by Ziye Yang's avatar Ziye Yang Committed by Changpeng Liu
Browse files

nvmf: Add the TCP/IP transport related host test



This is the first patch to enable the automated perf
test with TCP transport, which is used to guard the
correctness of the TCP transport related code.

Change-Id: Ic3df3aeae6df2024e22e50be70c7c61e36f85243
Signed-off-by: default avatarZiye Yang <optimistyzy@gmail.com>
Reviewed-on: https://review.gerrithub.io/425699


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
parent b2fb5519
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
NVMF_PORT=4420
NVMF_IP_PREFIX="192.168.100"
NVMF_IP_LEAST_ADDR=8
NVMF_TCP_IP_ADDRESS="127.0.0.1"

if [ -z "$NVMF_APP" ]; then
	NVMF_APP=./app/nvmf_tgt/nvmf_tgt
+13 −3
Original line number Diff line number Diff line
@@ -14,9 +14,11 @@ set -e

RDMA_IP_LIST=$(get_available_rdma_ips)
NVMF_FIRST_TARGET_IP=$(echo "$RDMA_IP_LIST" | head -n 1)
TYPES="TCP"
if [ -z $NVMF_FIRST_TARGET_IP ]; then
	echo "no NIC for nvmf test"
	exit 0
	echo "no RDMA NIC for nvmf test, will only test TCP/IP transport"
else
	TYPES=${TYPES}" RDMA"
fi

timing_enter perf
@@ -94,7 +96,15 @@ function test_perf()
	fi
}

test_perf "RDMA" $NVMF_FIRST_TARGET_IP
for type in $TYPES; do
	if [ $type == "TCP" ]; then
		nvmf_tgt_ip=$NVMF_TCP_IP_ADDRESS
	else
		nvmf_tgt_ip=$NVMF_FIRST_TARGET_IP
	fi

	test_perf $type $nvmf_tgt_ip
done

trap - SIGINT SIGTERM EXIT