From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f179.google.com (mail-wr0-f179.google.com [209.85.128.179]) by dpdk.org (Postfix) with ESMTP id EDFB92C1A for ; Mon, 10 Apr 2017 21:58:50 +0200 (CEST) Received: by mail-wr0-f179.google.com with SMTP id o21so127635544wrb.2 for ; Mon, 10 Apr 2017 12:58:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=r9XwsSF8hgfDNShUJx815k+yWptmsj5BJWVRVBBnwsQ=; b=WqZj3TRt4vlovRgQlDwEHhfcvxflY1ufLn5RtDL6tVLw/Qxb3p8PXZ0cJV5XtsIHbE o08gIFBQiSzd49aQ0jDgKT9urqT6uB3bpCABC1vRYJ9EEElskQxQy95OopOY6BmvrKuK 8Jn/urU6djOuSz7ZjTnKanpJS9GFd4yfX1o21qmlRCSVvQ3f3tTik4rAkN4bsxakwfRy kyOSVaU5heA42W4eD/xcuaYPOmyue7Vuw2NTI7NQA2KyWBs4ltP2dcfqQ0WGMK5XXFm3 U1JwkuJgJALkMT1+fFU0PL0ekimXyMDU6Epl4TYlPhvDMxLreEAawkXjOm5cppG40nML pmOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=r9XwsSF8hgfDNShUJx815k+yWptmsj5BJWVRVBBnwsQ=; b=rofiSZy0sS+81IBrXvk44rckgf93quNeJEKibAJyDW3YaBMj7PwMgThUpUCQxdlOhi xVU390TXJ+Ias48ACq5ZPnIPShIQC0xugLm+Xjpa0QS1InK+vMTPULo0oZepBeNXngQ1 XlPC4zW/XXKL6r4tsu5GuxN5H/cCTWJy8pVuoKwQ0SzltxQe5eE1wHKh2auXbKg17U2u EIwVz+3FQNYde4SHfxefg2WEZ/+zVu3q3LelAX/LjpMgqr/gDrNK7sjasoeiZS+kWUl8 mzgr7BYq+eZDA+GMc0Eh9vBWbDSu/+Ip4OG6cF4cP4S76ErIO+RwKanX3oD6V5IhtcJr QqoA== X-Gm-Message-State: AFeK/H37lB9zGp0O0Ub1/qrIGgiyRGmxh3QgzSisGm2O6POhnZVRxpGRYMVgP6D56T5mxUBl X-Received: by 10.223.167.145 with SMTP id j17mr42591501wrc.178.1491854330531; Mon, 10 Apr 2017 12:58:50 -0700 (PDT) Received: from neon (bc535-h01-176-146-114-125.dsl.sta.abo.bbox.fr. [176.146.114.125]) by smtp.gmail.com with ESMTPSA id w76sm16983653wrb.49.2017.04.10.12.58.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 10 Apr 2017 12:58:50 -0700 (PDT) Date: Mon, 10 Apr 2017 21:58:47 +0200 From: Olivier MATZ To: Hemant Agrawal Cc: , , , Message-ID: <20170410215847.704092d2@neon> In-Reply-To: <1491724786-6468-2-git-send-email-hemant.agrawal@nxp.com> References: <1489754838-1455-2-git-send-email-hemant.agrawal@nxp.com> <1491724786-6468-1-git-send-email-hemant.agrawal@nxp.com> <1491724786-6468-2-git-send-email-hemant.agrawal@nxp.com> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2] mempool/dpaa2: add DPAA2 hardware offloaded mempool X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Apr 2017 19:58:51 -0000 Hi Hemant, On Sun, 9 Apr 2017 13:29:46 +0530 Hemant Agrawal wrote: > DPAA2 Hardware Mempool handlers allow enqueue/dequeue from NXP's > QBMAN hardware block. > CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS is set to 'dpaa2', if the pool > is enabled. > > This memory pool currently supports packet mbuf type blocks only. > > Signed-off-by: Hemant Agrawal [...] > --- a/drivers/bus/Makefile > +++ b/drivers/bus/Makefile > @@ -33,6 +33,10 @@ include $(RTE_SDK)/mk/rte.vars.mk > > core-libs := librte_eal librte_mbuf librte_mempool librte_ring librte_ether > > +ifeq ($(CONFIG_RTE_LIBRTE_DPAA2_MEMPOOL),y) > +CONFIG_RTE_LIBRTE_FSLMC_BUS = $(CONFIG_RTE_LIBRTE_DPAA2_MEMPOOL) > +endif > + > DIRS-$(CONFIG_RTE_LIBRTE_FSLMC_BUS) += fslmc > DEPDIRS-fslmc = ${core-libs} > What's the purpose of this? Not sure we are allowed to modify the configs in the Makefiles. > + ret = dpbp_get_attributes(&avail_dpbp->dpbp, CMD_PRI_LOW, > + avail_dpbp->token, &dpbp_attr); > + if (ret != 0) { > + PMD_INIT_LOG(ERR, "Resource read failure with" > + " err code: %d\n", ret); > + p_ret = ret; > + ret = dpbp_disable(&avail_dpbp->dpbp, CMD_PRI_LOW, > + avail_dpbp->token); > + return p_ret; > + } > + > + /* Allocate the bp_list which will be added into global_bp_list */ > + bp_list = (struct dpaa2_bp_list *)malloc(sizeof(struct dpaa2_bp_list)); > + if (!bp_list) { > + PMD_INIT_LOG(ERR, "No heap memory available"); > + return -ENOMEM; > + } > + I think the cast is not needed. Are you sure you want to use malloc() and not rte_malloc()? It would be in hugepages. [...] > > I still have some concerns about the fact that the mempool handler assumes that the objects are necessarily mbufs. I guess for this reason it does not pass mempool autotests? We should probably move forward and let it go in 17.05, but this is something that should be enhanced in my opinion. Regards, Olivier