Commit a25b1619 authored by Michal Berger's avatar Michal Berger Committed by Konrad Sztyber
Browse files

test/nvme/xnvme: Enable polling in nvme driver



Under latest linux kernels (>=6.11.x) the underlying filename must
support polled io for the uring's IOPOLL to work. Since we use
nvme for these tests, make sure number of polling queues is
> 0 while setting up the driver.

in blockdev.sh xnvme is not the critical part of the tests so instead
of playing with nvme driver, we simply enable conserve_cpu which skips
IOPOLL setup altogether.

Change-Id: I63771c63a8be8bc3415c098ffeefa4475b8dc7ed
Signed-off-by: default avatarMichal Berger <michal.berger@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/25321


Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarKonrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: default avatarKarl Bonde Torp <k.torp@samsung.com>
Community-CI: Community CI Samsung <spdk.community.ci.samsung@gmail.com>
Reviewed-by: default avatarJim Harris <jim.harris@nvidia.com>
parent bb53e3ad
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -93,7 +93,7 @@ function setup_xnvme_conf() {

	for nvme in /dev/nvme*n*; do
		[[ -b $nvme && -z ${zoned_devs["${nvme##*/}"]} ]] || continue
		nvmes+=("bdev_xnvme_create $nvme ${nvme##*/} $io_mechanism")
		nvmes+=("bdev_xnvme_create $nvme ${nvme##*/} $io_mechanism -c")
	done

	((${#nvmes[@]} > 0))
+10 −0
Original line number Diff line number Diff line
@@ -67,6 +67,16 @@ rpc_xnvme() {
		| jq -r ".[] | select(.method == \"bdev_xnvme_create\").params.${1:-name}"
}

prep_nvme() {
	"$rootdir/scripts/setup.sh" reset

	# Make sure io_poll gets enabled
	modprobe -r nvme
	modprobe nvme poll_queues=$(nproc)
}

prep_nvme

for dev in "${xnvme_filename[@]}"; do
	[[ -e $dev ]]
done
+0 −2
Original line number Diff line number Diff line
@@ -6,8 +6,6 @@

testdir=$(readlink -f "$(dirname "$0")")
rootdir=$(readlink -f "$testdir/../../../")

"$rootdir/scripts/setup.sh" reset
source "$testdir/common.sh"

xnvme_bdevperf() {