From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 07AC61B556 for ; Thu, 7 Feb 2019 14:28:03 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 43EE4C7065; Thu, 7 Feb 2019 13:28:01 +0000 (UTC) Received: from ktraynor.remote.csb (unknown [10.33.36.135]) by smtp.corp.redhat.com (Postfix) with ESMTP id 864E5620DE; Thu, 7 Feb 2019 13:27:59 +0000 (UTC) From: Kevin Traynor To: Hari Kumar Vemula Cc: Honnappa Nagarahalli , Reshma Pattan , Pablo de Lara , dpdk stable Date: Thu, 7 Feb 2019 13:25:39 +0000 Message-Id: <20190207132614.20538-33-ktraynor@redhat.com> In-Reply-To: <20190207132614.20538-1-ktraynor@redhat.com> References: <20190207132614.20538-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Thu, 07 Feb 2019 13:28:01 +0000 (UTC) Subject: [dpdk-stable] patch 'efd: fix tail queue leak' has been queued to LTS release 18.11.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 Feb 2019 13:28:03 -0000 Hi, FYI, your patch has been queued to LTS release 18.11.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 02/14/19. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Thanks. Kevin Traynor --- >>From b6b78b5e02731b2a1161eadeb2aa8feaba2feb79 Mon Sep 17 00:00:00 2001 From: Hari Kumar Vemula Date: Fri, 18 Jan 2019 07:40:42 +0000 Subject: [PATCH] efd: fix tail queue leak [ upstream commit c749c032252997cf50cbe3620a7edd30532423af ] In rte_efd_create() allocated memory for tail queue entry but not freed. Added freeing the tail queue entry. Fixes: 56b6ef874f80 ("efd: new Elastic Flow Distributor library") Signed-off-by: Hari Kumar Vemula Reviewed-by: Honnappa Nagarahalli Acked-by: Reshma Pattan Acked-by: Pablo de Lara --- lib/librte_efd/rte_efd.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/lib/librte_efd/rte_efd.c b/lib/librte_efd/rte_efd.c index e6e5cfda2..1a97ece05 100644 --- a/lib/librte_efd/rte_efd.c +++ b/lib/librte_efd/rte_efd.c @@ -741,4 +741,6 @@ rte_efd_free(struct rte_efd_table *table) { uint8_t socket_id; + struct rte_efd_list *efd_list; + struct rte_tailq_entry *te, *temp; if (table == NULL) @@ -748,4 +750,16 @@ rte_efd_free(struct rte_efd_table *table) rte_free(table->chunks[socket_id]); + efd_list = RTE_TAILQ_CAST(rte_efd_tailq.head, rte_efd_list); + rte_rwlock_write_lock(RTE_EAL_TAILQ_RWLOCK); + + TAILQ_FOREACH_SAFE(te, efd_list, next, temp) { + if (te->data == (void *) table) { + TAILQ_REMOVE(efd_list, te, next); + rte_free(te); + break; + } + } + + rte_rwlock_write_unlock(RTE_EAL_TAILQ_RWLOCK); rte_ring_free(table->free_slots); rte_free(table->offline_chunks); -- 2.19.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-02-07 13:19:56.314034743 +0000 +++ 0033-efd-fix-tail-queue-leak.patch 2019-02-07 13:19:55.000000000 +0000 @@ -1,14 +1,15 @@ -From c749c032252997cf50cbe3620a7edd30532423af Mon Sep 17 00:00:00 2001 +From b6b78b5e02731b2a1161eadeb2aa8feaba2feb79 Mon Sep 17 00:00:00 2001 From: Hari Kumar Vemula Date: Fri, 18 Jan 2019 07:40:42 +0000 Subject: [PATCH] efd: fix tail queue leak +[ upstream commit c749c032252997cf50cbe3620a7edd30532423af ] + In rte_efd_create() allocated memory for tail queue entry but not freed. Added freeing the tail queue entry. Fixes: 56b6ef874f80 ("efd: new Elastic Flow Distributor library") -Cc: stable@dpdk.org Signed-off-by: Hari Kumar Vemula Reviewed-by: Honnappa Nagarahalli