summaryrefslogtreecommitdiff
path: root/drivers/mempool
diff options
context:
space:
mode:
authorShreyansh Jain <shreyansh.jain@nxp.com>2018-10-15 17:31:55 +0530
committerThomas Monjalon <thomas@monjalon.net>2018-10-16 14:54:25 +0200
commit5a7dbb934d75395aa1a03dfd0ad2a66028a62c1b (patch)
tree04e9f9bbc7aed7ce719550340d2afe614b1b7dad /drivers/mempool
parent2f3d633aa593c89c86dfb0e7df75e49ee05ad808 (diff)
downloaddpdk-5a7dbb934d75395aa1a03dfd0ad2a66028a62c1b.zip
dpdk-5a7dbb934d75395aa1a03dfd0ad2a66028a62c1b.tar.gz
dpdk-5a7dbb934d75395aa1a03dfd0ad2a66028a62c1b.tar.xz
dpaa: enable dpaax library
With this patch, dpaa bus and ethernet devices on this bus would start using the physical-virtual library interfaces. This patch impacts mempool/dpaa, event/dpaa and net/dpaa as they are dependent on the bus/dpaa and thus impact linkage of libraries. Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Diffstat (limited to 'drivers/mempool')
-rw-r--r--drivers/mempool/dpaa/Makefile1
-rw-r--r--drivers/mempool/dpaa/dpaa_mempool.c4
-rw-r--r--drivers/mempool/dpaa/dpaa_mempool.h4
3 files changed, 6 insertions, 3 deletions
diff --git a/drivers/mempool/dpaa/Makefile b/drivers/mempool/dpaa/Makefile
index da8da1e..9cf3685 100644
--- a/drivers/mempool/dpaa/Makefile
+++ b/drivers/mempool/dpaa/Makefile
@@ -31,5 +31,6 @@ SRCS-$(CONFIG_RTE_LIBRTE_DPAA_MEMPOOL) += dpaa_mempool.c
LDLIBS += -lrte_bus_dpaa
LDLIBS += -lrte_eal -lrte_mempool -lrte_ring
+LDLIBS += -lrte_common_dpaax
include $(RTE_SDK)/mk/rte.lib.mk
diff --git a/drivers/mempool/dpaa/dpaa_mempool.c b/drivers/mempool/dpaa/dpaa_mempool.c
index 1c12122..b05fb7b 100644
--- a/drivers/mempool/dpaa/dpaa_mempool.c
+++ b/drivers/mempool/dpaa/dpaa_mempool.c
@@ -26,6 +26,7 @@
#include <rte_ring.h>
#include <dpaa_mempool.h>
+#include <dpaax_iova_table.h>
/* List of all the memseg information locally maintained in dpaa driver. This
* is to optimize the PA_to_VA searches until a better mechanism (algo) is
@@ -285,6 +286,9 @@ dpaa_populate(struct rte_mempool *mp, unsigned int max_objs,
return 0;
}
+ /* Update the PA-VA Table */
+ dpaax_iova_table_update(paddr, vaddr, len);
+
bp_info = DPAA_MEMPOOL_TO_POOL_INFO(mp);
total_elt_sz = mp->header_size + mp->elt_size + mp->trailer_size;
diff --git a/drivers/mempool/dpaa/dpaa_mempool.h b/drivers/mempool/dpaa/dpaa_mempool.h
index 092f326..533e1c6 100644
--- a/drivers/mempool/dpaa/dpaa_mempool.h
+++ b/drivers/mempool/dpaa/dpaa_mempool.h
@@ -43,10 +43,8 @@ struct dpaa_bp_info {
};
static inline void *
-DPAA_MEMPOOL_PTOV(struct dpaa_bp_info *bp_info, uint64_t addr)
+DPAA_MEMPOOL_PTOV(struct dpaa_bp_info *bp_info __rte_unused, uint64_t addr)
{
- if (bp_info->ptov_off)
- return ((void *) (size_t)(addr + bp_info->ptov_off));
return rte_dpaa_mem_ptov(addr);
}