From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7B43AA04C7; Tue, 15 Sep 2020 17:55:23 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 17D261C000; Tue, 15 Sep 2020 17:55:23 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by dpdk.org (Postfix) with ESMTP id 9CEE11BFC5; Tue, 15 Sep 2020 17:55:21 +0200 (CEST) IronPort-SDR: bdAp3ROkkTH2UZd2Gbz2TTesG/9J3GYlnxk3mQLJq569Z9r4vlPXsim88j26PrESH7EKktsoDR 48Fahkw2dPNg== X-IronPort-AV: E=McAfee;i="6000,8403,9745"; a="139291869" X-IronPort-AV: E=Sophos;i="5.76,430,1592895600"; d="scan'208";a="139291869" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Sep 2020 08:55:19 -0700 IronPort-SDR: UFcoBmxTPN/P1M0uU6p/XbnOhD5ukEcI458adbZK585CBElXGPZhgVvooSXtZE4vZGYgemQDDk 4TbcLRm3kOGA== X-IronPort-AV: E=Sophos;i="5.76,430,1592895600"; d="scan'208";a="482874909" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.27.22]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 15 Sep 2020 08:55:17 -0700 Date: Tue, 15 Sep 2020 16:55:12 +0100 From: Bruce Richardson To: Ruifeng Wang Cc: Vladimir Medvedkin , Ray Kinsella , Honnappa Nagarahalli , dev@dpdk.org, nd@arm.com, stable@dpdk.org Message-ID: <20200915152613.GA811@bricha3-MOBL.ger.corp.intel.com> References: <20200907081518.46350-1-ruifeng.wang@arm.com> <20200907081518.46350-2-ruifeng.wang@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200907081518.46350-2-ruifeng.wang@arm.com> Subject: Re: [dpdk-dev] [PATCH 1/2] lpm: fix free of data structure 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, Sep 07, 2020 at 04:15:16PM +0800, Ruifeng Wang wrote: > The container structure should be freed instead of rte_lpm structure > after wrapping rte_lpm into internal structure __rte_lpm. > > Fixes: 8a9f8564e9f9 ("lpm: implement RCU rule reclamation") > Cc: stable@dpdk.org > > Signed-off-by: Ruifeng Wang > Reviewed-by: Phil Yang > --- > lib/librte_lpm/rte_lpm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/librte_lpm/rte_lpm.c b/lib/librte_lpm/rte_lpm.c > index 757436f49..51a0ae578 100644 > --- a/lib/librte_lpm/rte_lpm.c > +++ b/lib/librte_lpm/rte_lpm.c > @@ -268,7 +268,7 @@ rte_lpm_free(struct rte_lpm *lpm) > rte_rcu_qsbr_dq_delete(internal_lpm->dq); > rte_free(lpm->tbl8); > rte_free(lpm->rules_tbl); > - rte_free(lpm); > + rte_free(internal_lpm); > rte_free(te); > } > > -- Acked-by: Bruce Richardson