bus/dpaa: register platform HW mempool on runtime
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
This commit is contained in:
parent
0e79856795
commit
2bd0d5b951
@ -25,7 +25,6 @@ CONFIG_RTE_LIBRTE_DPAA_HWDEBUG=n
|
||||
|
||||
# NXP DPAA Mempool
|
||||
CONFIG_RTE_LIBRTE_DPAA_MEMPOOL=y
|
||||
CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS="dpaa"
|
||||
|
||||
# Compile software NXP DPAA PMD
|
||||
CONFIG_RTE_LIBRTE_DPAA_PMD=y
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <rte_malloc.h>
|
||||
#include <rte_ring.h>
|
||||
#include <rte_bus.h>
|
||||
#include <rte_mbuf_pool_ops.h>
|
||||
|
||||
#include <rte_dpaa_bus.h>
|
||||
#include <rte_dpaa_logs.h>
|
||||
@ -469,6 +470,7 @@ rte_dpaa_bus_probe(void)
|
||||
break;
|
||||
}
|
||||
}
|
||||
rte_mbuf_set_platform_mempool_ops(DPAA_MEMPOOL_OPS_NAME);
|
||||
|
||||
svr_file = fopen(DPAA_SOC_ID_FILE, "r");
|
||||
if (svr_file) {
|
||||
|
@ -17,6 +17,8 @@
|
||||
|
||||
#define FSL_DPAA_BUS_NAME "FSL_DPAA_BUS"
|
||||
|
||||
#define DPAA_MEMPOOL_OPS_NAME "dpaa"
|
||||
|
||||
#define DEV_TO_DPAA_DEVICE(ptr) \
|
||||
container_of(ptr, struct rte_dpaa_device, device)
|
||||
|
||||
|
@ -290,7 +290,7 @@ dpaa_register_memory_area(const struct rte_mempool *mp,
|
||||
}
|
||||
|
||||
struct rte_mempool_ops dpaa_mpool_ops = {
|
||||
.name = "dpaa",
|
||||
.name = DPAA_MEMPOOL_OPS_NAME,
|
||||
.alloc = dpaa_mbuf_create_pool,
|
||||
.free = dpaa_mbuf_free_pool,
|
||||
.enqueue = dpaa_mbuf_free_bulk,
|
||||
|
Loading…
x
Reference in New Issue
Block a user