summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnatoly Burakov <anatoly.burakov@intel.com>2019-10-24 13:18:24 +0100
committerDavid Marchand <david.marchand@redhat.com>2019-11-07 17:46:43 +0100
commitb14d192ca1fc7575f415f363990c202cece84e28 (patch)
tree04291b9170b1ee3da1603974cfbae15f4a9d6f8f
parent9362945d7e79ca292215a8875055998928d36e74 (diff)
downloaddpdk-b14d192ca1fc7575f415f363990c202cece84e28.zip
dpdk-b14d192ca1fc7575f415f363990c202cece84e28.tar.gz
dpdk-b14d192ca1fc7575f415f363990c202cece84e28.tar.xz
vfio: remove deprecated DMA mapping functions
The rte_vfio_dma_map/unmap API's have been marked as deprecated in release 19.05. Remove them. Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com> Acked-by: David Marchand <david.marchand@redhat.com> Acked-by: Thomas Monjalon <thomas@monjalon.net>
-rw-r--r--doc/guides/rel_notes/deprecation.rst4
-rw-r--r--doc/guides/rel_notes/release_19_11.rst5
-rw-r--r--lib/librte_eal/common/include/rte_vfio.h44
-rw-r--r--lib/librte_eal/freebsd/eal/eal.c14
-rw-r--r--lib/librte_eal/linux/eal/eal_vfio.c36
-rw-r--r--lib/librte_eal/rte_eal_version.map2
6 files changed, 5 insertions, 100 deletions
diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst
index 4249aab..b0b992d 100644
--- a/doc/guides/rel_notes/deprecation.rst
+++ b/doc/guides/rel_notes/deprecation.rst
@@ -38,10 +38,6 @@ Deprecation Notices
remove it from the externally visible ABI and allow it to be updated in the
future.
-* vfio: removal of ``rte_vfio_dma_map`` and ``rte_vfio_dma_unmap`` APIs which
- have been replaced with ``rte_dev_dma_map`` and ``rte_dev_dma_unmap``
- functions. The due date for the removal targets DPDK 20.02.
-
* dpaa2: removal of ``rte_dpaa2_memsegs`` structure which has been replaced
by a pa-va search library. This structure was earlier being used for holding
memory segments used by dpaa2 driver for faster pa->va translation. This
diff --git a/doc/guides/rel_notes/release_19_11.rst b/doc/guides/rel_notes/release_19_11.rst
index 03e58e0..fe11b4b 100644
--- a/doc/guides/rel_notes/release_19_11.rst
+++ b/doc/guides/rel_notes/release_19_11.rst
@@ -317,6 +317,11 @@ API Changes
* mem: hid the internal ``malloc_heap`` structure and the
``rte_malloc_heap.h`` header.
+* vfio: removed ``rte_vfio_dma_map`` and ``rte_vfio_dma_unmap`` that have
+ been marked as deprecated in release 19.05.
+ ``rte_vfio_container_dma_map`` and ``rte_vfio_container_dma_unmap`` can
+ be used as substitutes.
+
* pci: removed the following functions deprecated since dpdk v17.11:
- ``eal_parse_pci_BDF`` replaced by ``rte_pci_addr_parse``
diff --git a/lib/librte_eal/common/include/rte_vfio.h b/lib/librte_eal/common/include/rte_vfio.h
index b360485..20ed8c4 100644
--- a/lib/librte_eal/common/include/rte_vfio.h
+++ b/lib/librte_eal/common/include/rte_vfio.h
@@ -190,50 +190,6 @@ int
rte_vfio_clear_group(int vfio_group_fd);
/**
- * Map memory region for use with VFIO.
- *
- * @note Require at least one device to be attached at the time of
- * mapping. DMA maps done via this API will only apply to default
- * container and will not apply to any of the containers created
- * via rte_vfio_container_create().
- *
- * @param vaddr
- * Starting virtual address of memory to be mapped.
- *
- * @param iova
- * Starting IOVA address of memory to be mapped.
- *
- * @param len
- * Length of memory segment being mapped.
- *
- * @return
- * 0 if success.
- * -1 on error.
- */
-int
-rte_vfio_dma_map(uint64_t vaddr, uint64_t iova, uint64_t len);
-
-
-/**
- * Unmap memory region from VFIO.
- *
- * @param vaddr
- * Starting virtual address of memory to be unmapped.
- *
- * @param iova
- * Starting IOVA address of memory to be unmapped.
- *
- * @param len
- * Length of memory segment being unmapped.
- *
- * @return
- * 0 if success.
- * -1 on error.
- */
-
-int
-rte_vfio_dma_unmap(uint64_t vaddr, uint64_t iova, uint64_t len);
-/**
* Parse IOMMU group number for a device
*
* This function is only relevant to linux and will return
diff --git a/lib/librte_eal/freebsd/eal/eal.c b/lib/librte_eal/freebsd/eal/eal.c
index 511d8d7..6ae37e7 100644
--- a/lib/librte_eal/freebsd/eal/eal.c
+++ b/lib/librte_eal/freebsd/eal/eal.c
@@ -1028,20 +1028,6 @@ int rte_vfio_clear_group(__rte_unused int vfio_group_fd)
}
int
-rte_vfio_dma_map(uint64_t __rte_unused vaddr, __rte_unused uint64_t iova,
- __rte_unused uint64_t len)
-{
- return -1;
-}
-
-int
-rte_vfio_dma_unmap(uint64_t __rte_unused vaddr, uint64_t __rte_unused iova,
- __rte_unused uint64_t len)
-{
- return -1;
-}
-
-int
rte_vfio_get_group_num(__rte_unused const char *sysfs_base,
__rte_unused const char *dev_addr,
__rte_unused int *iommu_group_num)
diff --git a/lib/librte_eal/linux/eal/eal_vfio.c b/lib/librte_eal/linux/eal/eal_vfio.c
index d788738..58c0f85 100644
--- a/lib/librte_eal/linux/eal/eal_vfio.c
+++ b/lib/librte_eal/linux/eal/eal_vfio.c
@@ -1833,28 +1833,6 @@ out:
}
int
-rte_vfio_dma_map(uint64_t vaddr, uint64_t iova, uint64_t len)
-{
- if (len == 0) {
- rte_errno = EINVAL;
- return -1;
- }
-
- return container_dma_map(default_vfio_cfg, vaddr, iova, len);
-}
-
-int
-rte_vfio_dma_unmap(uint64_t vaddr, uint64_t iova, uint64_t len)
-{
- if (len == 0) {
- rte_errno = EINVAL;
- return -1;
- }
-
- return container_dma_unmap(default_vfio_cfg, vaddr, iova, len);
-}
-
-int
rte_vfio_noiommu_is_enabled(void)
{
int fd;
@@ -2032,20 +2010,6 @@ rte_vfio_container_dma_unmap(int container_fd, uint64_t vaddr, uint64_t iova,
#else
int
-rte_vfio_dma_map(uint64_t __rte_unused vaddr, __rte_unused uint64_t iova,
- __rte_unused uint64_t len)
-{
- return -1;
-}
-
-int
-rte_vfio_dma_unmap(uint64_t __rte_unused vaddr, uint64_t __rte_unused iova,
- __rte_unused uint64_t len)
-{
- return -1;
-}
-
-int
rte_vfio_setup_device(__rte_unused const char *sysfs_base,
__rte_unused const char *dev_addr,
__rte_unused int *vfio_dev_fd,
diff --git a/lib/librte_eal/rte_eal_version.map b/lib/librte_eal/rte_eal_version.map
index 3478d3b..f1982f2 100644
--- a/lib/librte_eal/rte_eal_version.map
+++ b/lib/librte_eal/rte_eal_version.map
@@ -245,8 +245,6 @@ DPDK_18.08 {
rte_vfio_container_dma_unmap;
rte_vfio_container_group_bind;
rte_vfio_container_group_unbind;
- rte_vfio_dma_map;
- rte_vfio_dma_unmap;
rte_vfio_get_container_fd;
rte_vfio_get_group_fd;
rte_vfio_get_group_num;