vhost: QEMU arguments changed to fit patches on QEMU mailing list

This patch changes following:
- device renamed to vhost-user-scsi-pci
- VM image set as first in boot order

Additionally cleaned up test paths.

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Signed-off-by: Krzysztof Jakimiak <krzysztof.jakimiak@intel.com>
Change-Id: Ib89954ba083bf047e1a46bc350345e42272badd9
This commit is contained in:
Tomasz Zawadzki 2017-03-20 11:41:15 +01:00 committed by Daniel Verkamp
parent 1054432d06
commit d329d85774
3 changed files with 13 additions and 9 deletions

View File

@ -64,6 +64,6 @@
<qemu:arg value="-chardev"/>
<qemu:arg value="socket,id=char0,path=/tmp/naa.123"/>
<qemu:arg value="-device"/>
<qemu:arg value="vhost-scsi-pci,id=scsi0,wwpn=naa.123,user=true,chardev=char0"/>
<qemu:arg value="vhost-user-scsi-pci,id=scsi0,chardev=char0"/>
</qemu:commandline>
</domain>

View File

@ -58,7 +58,10 @@ function error()
function qemu_build_and_install()
{
mkdir -p $QEMU_BUILD_DIR
cd $QEMU_BUILD_DIR
cd $QEMU_SRC_DIR
make clean
cd $QEMU_BUILD_DIR
echo "INFO: Configuring QEMU from source in $QEMU_SRC_DIR"
if type ccache > /dev/null 2>&1; then
@ -466,7 +469,8 @@ function vm_setup()
cmd+="-net user,hostfwd=tcp::$ssh_socket-:22,hostfwd=tcp::$fio_socket-:8765,hostfwd=tcp::$https_socket-:443,hostfwd=tcp::$http_socket-:80 ${eol}"
cmd+="-net nic ${eol}"
cmd+="-hda $os ${eol}"
cmd+="-drive file=$os,if=none,id=os_disk ${eol}"
cmd+="-device ide-hd,drive=os_disk,bootindex=0 ${eol}"
IFS=':'
@ -509,7 +513,7 @@ function vm_setup()
echo "INFO: using socket $SPDK_VHOST_SCSI_TEST_DIR/naa.$disk.$vm_num"
cmd+="-chardev socket,id=char_$disk,path=$SPDK_VHOST_SCSI_TEST_DIR/naa.$disk.$vm_num ${eol}"
cmd+="-device vhost-scsi-pci,id=scsi_$disk,wwpn=unused,num_queues=$cpu_num,user=true,chardev=char_$disk ${eol}"
cmd+="-device vhost-user-scsi-pci,id=scsi_$disk,num_queues=$cpu_num,chardev=char_$disk ${eol}"
;;
kernel_vhost)
if [[ -z $disk ]]; then

View File

@ -2,7 +2,7 @@
set -e
if [ ! -f "/home/sys_sgsw/vhost_scsi_vm_image.qcow2" ]; then
if [ ! -f "/home/sys_sgsw/vhost_vm_image.qcow2" ]; then
echo "VM does not exist, exiting vhost tests without running"
exit 0
fi
@ -21,18 +21,18 @@ case $param in
-p|--performance)
echo Running performance suite...
./fiotest/autotest.sh --fio-bin=/home/sys_sgsw/fio_ubuntu \
--vm=0,/home/sys_sgsw/vhost_scsi_vm_image.qcow2,Nvme0n1p0 \
--vm=0,/home/sys_sgsw/vhost_vm_image.qcow2,Nvme0n1p0 \
--test-type=spdk_vhost \
--fio-jobs=$WORKDIR/fiotest/fio_jobs/default_performance.job \
--qemu-src=/home/sys_sgsw/vhost_scsi/qemu
--qemu-src=/home/sys_sgsw/vhost/qemu
;;
-i|--integrity)
echo Running integrity suite...
./fiotest/autotest.sh --fio-bin=/home/sys_sgsw/fio_ubuntu \
--vm=0,/home/sys_sgsw/vhost_scsi_vm_image.qcow2,Nvme0n1p0:Nvme0n1p1:Nvme0n1p2:Nvme0n1p3 \
--vm=0,/home/sys_sgsw/vhost_vm_image.qcow2,Nvme0n1p0:Nvme0n1p1:Nvme0n1p2:Nvme0n1p3 \
--test-type=spdk_vhost \
--fio-jobs=$WORKDIR/fiotest/fio_jobs/default_integrity.job \
--qemu-src=/home/sys_sgsw/vhost_scsi/qemu
--qemu-src=/home/sys_sgsw/vhost/qemu
;;
-h|--help)
echo "-i|--integrity for running an integrity test"