summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Harris <james.r.harris@intel.com>2019-09-24 02:23:34 -0700
committerFerruh Yigit <ferruh.yigit@intel.com>2019-10-07 15:00:57 +0200
commit61af1713d3f1bebf896aeb943fc23f58ed4f0724 (patch)
treea6c229104011c04668ab2a040e2cccfa6cb387b6
parentf2f4990eff941227aa346502f518acd490fb5d18 (diff)
downloaddpdk-61af1713d3f1bebf896aeb943fc23f58ed4f0724.zip
dpdk-61af1713d3f1bebf896aeb943fc23f58ed4f0724.tar.gz
dpdk-61af1713d3f1bebf896aeb943fc23f58ed4f0724.tar.xz
vhost: add missing experimental flag
This function is listed under EXPERIMENTAL in the rte_vhost_version.map, so it needs to be marked with __rte_experimental in the header file as well. Found by check-experimental-syms.sh when trying to compile DPDK with -finstrument-functions. This script didn't catch this in the normal case, since the function is declared __rte_always_inline. This also requires updating the vhost_scsi example to allow use of this newly marked experimental API. Signed-off-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
-rw-r--r--examples/vhost_scsi/Makefile1
-rw-r--r--examples/vhost_scsi/meson.build1
-rw-r--r--lib/librte_vhost/rte_vhost.h1
3 files changed, 3 insertions, 0 deletions
diff --git a/examples/vhost_scsi/Makefile b/examples/vhost_scsi/Makefile
index c5aec26..05e1ced 100644
--- a/examples/vhost_scsi/Makefile
+++ b/examples/vhost_scsi/Makefile
@@ -58,6 +58,7 @@ please change the definition of the RTE_TARGET environment variable)
all:
else
+CFLAGS += -DALLOW_EXPERIMENTAL_API
CFLAGS += -D_FILE_OFFSET_BITS=64
CFLAGS += -O2
CFLAGS += $(WERROR_FLAGS)
diff --git a/examples/vhost_scsi/meson.build b/examples/vhost_scsi/meson.build
index 77e5201..384127d 100644
--- a/examples/vhost_scsi/meson.build
+++ b/examples/vhost_scsi/meson.build
@@ -15,6 +15,7 @@ if not cc.has_header('linux/virtio_scsi.h')
endif
deps += 'vhost'
+allow_experimental_apis = true
sources = files(
'scsi.c', 'vhost_scsi.c'
)
diff --git a/lib/librte_vhost/rte_vhost.h b/lib/librte_vhost/rte_vhost.h
index 878e339..19474bc 100644
--- a/lib/librte_vhost/rte_vhost.h
+++ b/lib/librte_vhost/rte_vhost.h
@@ -233,6 +233,7 @@ rte_vhost_gpa_to_vva(struct rte_vhost_memory *mem, uint64_t gpa)
* @return
* the host virtual address on success, 0 on failure
*/
+__rte_experimental
static __rte_always_inline uint64_t
rte_vhost_va_from_guest_pa(struct rte_vhost_memory *mem,
uint64_t gpa, uint64_t *len)