From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hemant Agrawal Subject: [PATCH FIX-OPTION-2 2/2] mbuf: fix user mempool ops get to use only named memzone Date: Fri, 2 Feb 2018 13:33:02 +0530 Message-ID: <1517558582-27108-3-git-send-email-hemant.agrawal@nxp.com> References: <1517514427-28843-1-git-send-email-hemant.agrawal@nxp.com> <1517558582-27108-1-git-send-email-hemant.agrawal@nxp.com> Mime-Version: 1.0 Content-Type: text/plain Cc: nipun.gupta@nxp.com, jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, dev@dpdk.org, Hemant Agrawal To: olivier.matz@6wind.com, thomas@monjalon.net, pbhagavatula@caviumnetworks.com Return-path: Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0062.outbound.protection.outlook.com [104.47.2.62]) by dpdk.org (Postfix) with ESMTP id A8F29A48D for ; Fri, 2 Feb 2018 09:04:46 +0100 (CET) In-Reply-To: <1517558582-27108-1-git-send-email-hemant.agrawal@nxp.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 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 --- lib/librte_mbuf/rte_mbuf_pool_ops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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; } -- 2.7.4