diff --git a/test/vhost/fiotest/fio.sh b/test/vhost/fiotest/fio.sh index 930948d6d..676186837 100755 --- a/test/vhost/fiotest/fio.sh +++ b/test/vhost/fiotest/fio.sh @@ -16,6 +16,7 @@ vms=() used_vms="" x="" readonly="" +packed=false function usage() { [[ -n $2 ]] && ( @@ -43,6 +44,7 @@ function usage() { echo " OS - VM os disk path (optional)" echo " DISKS - VM os test disks/devices path (virtio - optional, kernel_vhost - mandatory)" echo " --readonly Use readonly for fio" + echo " --packed Virtqueue format is packed" exit 0 } @@ -60,6 +62,7 @@ while getopts 'xh-:' optchar; do test-type=*) test_type="${OPTARG#*=}" ;; vm=*) vms+=("${OPTARG#*=}") ;; readonly) readonly="--readonly" ;; + packed) packed=true ;; *) usage $0 "Invalid argument '$OPTARG'" ;; esac ;; @@ -165,6 +168,10 @@ for vm_conf in "${vms[@]}"; do [[ x"${conf[1]}" != x"" ]] && setup_cmd+=" --os=${conf[1]}" [[ x"${conf[2]}" != x"" ]] && setup_cmd+=" --disks=${conf[2]}" + if [[ "$test_type" == "spdk_vhost_blk" ]] && $packed; then + setup_cmd+=" --packed" + fi + $setup_cmd done diff --git a/test/vhost/vhost.sh b/test/vhost/vhost.sh index 5b050fe40..78fe8306d 100755 --- a/test/vhost/vhost.sh +++ b/test/vhost/vhost.sh @@ -104,4 +104,11 @@ echo 'Running lvol integrity suite...' run_test "vhost_blk_lvol_integrity" $WORKDIR/lvol/lvol_test.sh -x --fio-bin=$FIO_BIN \ --ctrl-type=spdk_vhost_blk +echo 'Running blk packed ring integrity suite...' +run_test "vhost_blk_packed_ring_integrity" $WORKDIR/fiotest/fio.sh -x --fio-bin=$FIO_BIN \ + --vm=0,$VM_IMAGE,Nvme0n1p0 \ + --test-type=spdk_vhost_blk \ + --fio-job=$WORKDIR/common/fio_jobs/default_integrity.job \ + --packed + run_test "spdkcli_vhost" ./test/spdkcli/vhost.sh