From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ferruh Yigit Subject: Re: [PATCH 33/38] net/dpaa: add support for flow control Date: Wed, 28 Jun 2017 16:47:35 +0100 Message-ID: <108d2db3-8154-c108-13a7-722f861537af@intel.com> References: <1497591668-3320-1-git-send-email-shreyansh.jain@nxp.com> <1497591668-3320-34-git-send-email-shreyansh.jain@nxp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Cc: hemant.agrawal@nxp.com To: Shreyansh Jain , dev@dpdk.org Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id C1B542C8 for ; Wed, 28 Jun 2017 17:47:37 +0200 (CEST) In-Reply-To: <1497591668-3320-34-git-send-email-shreyansh.jain@nxp.com> Content-Language: en-US List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 6/16/2017 6:41 AM, Shreyansh Jain wrote: > Signed-off-by: Hemant Agrawal > Signed-off-by: Shreyansh Jain <...> > static int > +dpaa_flow_ctrl_set(struct rte_eth_dev *dev, > + struct rte_eth_fc_conf *fc_conf) > +{ > + struct dpaa_if *dpaa_intf = dev->data->dev_private; > + struct rte_eth_fc_conf *net_fc; > + > + PMD_INIT_FUNC_TRACE(); > + > + if (!(dpaa_intf->fc_conf)) { > + dpaa_intf->fc_conf = rte_zmalloc(NULL, > + sizeof(struct rte_eth_fc_conf), MAX_CACHELINE); Should this be freed in rte_dpaa_remove() > + if (!dpaa_intf->fc_conf) { > + PMD_DRV_LOG(ERR, "unable to save flow control info"); > + return -ENOMEM; > + } > + } > + net_fc = dpaa_intf->fc_conf; > + <...>