diff mbox series

[FIX-OPTION-2,2/2] mbuf: fix user mempool ops get to use only named memzone

Message ID 1517558582-27108-3-git-send-email-hemant.agrawal@nxp.com
State New
Headers show
Series [FIX-OPTION-2,1/2] eal: use named memzone to store user mempool ops name | expand

Commit Message

Hemant Agrawal Feb. 2, 2018, 8:03 a.m. UTC
The eal default mempool ops API can also return the compile
time default mempool ops name, which can break the best mempool
ops name logic.

Fixes: a3acc3144a76 ("mbuf: add pool ops selection functions")

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>

---
 lib/librte_mbuf/rte_mbuf_pool_ops.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
2.7.4
diff mbox series

Patch

diff --git a/lib/librte_mbuf/rte_mbuf_pool_ops.c b/lib/librte_mbuf/rte_mbuf_pool_ops.c
index 385fc43..a636c28 100644
--- a/lib/librte_mbuf/rte_mbuf_pool_ops.c
+++ b/lib/librte_mbuf/rte_mbuf_pool_ops.c
@@ -74,7 +74,7 @@  rte_mbuf_user_mempool_ops(void)
 
 	mz = rte_memzone_lookup("mbuf_user_pool_ops");
 	if (mz == NULL)
-		return rte_eal_mbuf_default_mempool_ops();
+		return NULL;
 	return mz->addr;
 }