From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id ADF2537A2 for ; Thu, 7 Dec 2017 18:15:19 +0100 (CET) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Dec 2017 09:15:18 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,373,1508828400"; d="scan'208";a="156848853" Received: from irsmsx152.ger.corp.intel.com ([163.33.192.66]) by orsmga004.jf.intel.com with ESMTP; 07 Dec 2017 09:15:17 -0800 Received: from irsmsx102.ger.corp.intel.com ([169.254.2.180]) by IRSMSX152.ger.corp.intel.com ([169.254.6.87]) with mapi id 14.03.0319.002; Thu, 7 Dec 2017 17:15:16 +0000 From: "Van Haaren, Harry" To: "Eads, Gage" , "dev@dpdk.org" CC: "jerin.jacob@caviumnetworks.com" , "Richardson, Bruce" , "hemant.agrawal@nxp.com" , "nipun.gupta@nxp.com" , "santosh.shukla@caviumnetworks.com" , "pbhagavatula@caviumnetworks.com" Thread-Topic: [PATCH 1/2] event/sw: fix queue memory leak and multi-link bug Thread-Index: AQHTaYih0pHxksXmSU23BrLGUZwFE6M4IAhw Date: Thu, 7 Dec 2017 17:15:16 +0000 Message-ID: References: <1512011314-19682-1-git-send-email-gage.eads@intel.com> In-Reply-To: <1512011314-19682-1-git-send-email-gage.eads@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMjk2YTVhMjMtNjlmZS00NWI0LWFiNjQtYTg5OWIwZWYyYjc3IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE2LjUuOS4zIiwiVHJ1c3RlZExhYmVsSGFzaCI6IjBcL3l6XC96UkpxamdPa25ncFZhSHppNHduNklsU1BrNWRlOTVlaXhMSE1vbz0ifQ== x-ctpclassification: CTP_IC dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH 1/2] event/sw: fix queue memory leak and multi-link bug 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: Thu, 07 Dec 2017 17:15:20 -0000 > From: Eads, Gage > Sent: Thursday, November 30, 2017 3:09 AM > To: dev@dpdk.org > Cc: jerin.jacob@caviumnetworks.com; Van Haaren, Harry > ; Richardson, Bruce > ; hemant.agrawal@nxp.com; nipun.gupta@nxp.com= ; > santosh.shukla@caviumnetworks.com; pbhagavatula@caviumnetworks.com > Subject: [PATCH 1/2] event/sw: fix queue memory leak and multi-link bug >=20 > This commit reinitializes a queue before it is reconfigured, such that > reorder buffer memory is not leaked. >=20 > This bug masked a few other problems, which this commit corrects as well: > - sw_port_link() allowed a port to link to a queue twice, such that the > port could then successfully unlink the queue twice. Now the link > function checks whether a port is already linked to the queue, and if s= o > returns success but doesn't assign the a port a second slot in the > queue's cq map. > - test_eventdev.c's test_eventdev_unlink() was unlinking a queue twice > from the same port, and expecting the second unlink to succeed. Now the > test unlinks, links, then unlinks again. > - test_eventdev.c's test_eventdev_link_get() was linking a single queue b= ut > expecting the unlink function to return nb_queues (where nb_queues > 1)= . > The test now checks for a return value of 1. >=20 > Fixes: 5ffb2f142d95 ("event/sw: support event queues") > Fixes: 371a688fc159 ("event/sw: support linking queues to ports") > Fixes: f8f9d233ea0e ("test/eventdev: add unit tests") >=20 > Signed-off-by: Gage Eads Looks good to me, Acked-by: Harry van Haaren