From 07e31b028aeaafe47abeff3be0729729bc4c493a Mon Sep 17 00:00:00 2001 From: Tomasz Zawadzki Date: Thu, 19 May 2022 16:59:39 +0200 Subject: [PATCH] ut/vhost: select vhost_backend for UT As of right now the UT always used the empty struture of struct spdk_vhost_dev_backend during the test. This meant VHOST_BACKEND_BLK. alloc_vdev() will require further changes to test both types of backends. So for now change it to VHOST_BACKEND_SCSI, since it currently does not touch any fields outside of the struct spdk_vhost_dev. Meanwhile next patch will do so for blk backend. Signed-off-by: Tomasz Zawadzki Change-Id: Ib5af7520bc8a21a7af03b810d4cc42726797a331 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12749 Tested-by: SPDK CI Jenkins Community-CI: Broadcom CI Reviewed-by: Jim Harris Reviewed-by: Konrad Sztyber --- test/unit/lib/vhost/vhost.c/vhost_ut.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/lib/vhost/vhost.c/vhost_ut.c b/test/unit/lib/vhost/vhost.c/vhost_ut.c index d35c8f831..ba9946ba8 100644 --- a/test/unit/lib/vhost/vhost.c/vhost_ut.c +++ b/test/unit/lib/vhost/vhost.c/vhost_ut.c @@ -167,7 +167,7 @@ spdk_call_unaffinitized(void *cb(void *arg), void *arg) return cb(arg); } -static struct spdk_vhost_dev_backend g_vdev_backend; +static struct spdk_vhost_dev_backend g_vdev_backend = {.type = VHOST_BACKEND_SCSI}; static struct spdk_vhost_user_dev_backend g_vdev_user_backend; static bool g_init_fail;