From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 86E70A034F; Thu, 24 Jun 2021 10:43:54 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 675B340141; Thu, 24 Jun 2021 10:43:54 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mails.dpdk.org (Postfix) with ESMTP id 25D054003C for ; Thu, 24 Jun 2021 10:43:52 +0200 (CEST) IronPort-SDR: PKRH2mLdpVce0zQ3OgDCnfSFZmz6zGnJzdbSBsjkQkyP91AoRQ7+E7XdSHQ2vUPx21R0lUhj7M dHOGvFRxmHnQ== X-IronPort-AV: E=McAfee;i="6200,9189,10024"; a="207245933" X-IronPort-AV: E=Sophos;i="5.83,296,1616482800"; d="scan'208";a="207245933" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2021 01:43:52 -0700 IronPort-SDR: mGyWtgles+sf8f6PUcJRkAYuBue131QHJNB4rZe3xsxnsLihO5MNKqOoKHdyfI6fG6xO7xHQFH M8aVmbTNk/Qw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.83,296,1616482800"; d="scan'208";a="418005836" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by fmsmga007.fm.intel.com with ESMTP; 24 Jun 2021 01:43:52 -0700 Received: from orsmsx608.amr.corp.intel.com (10.22.229.21) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.4; Thu, 24 Jun 2021 01:43:51 -0700 Received: from orsmsx609.amr.corp.intel.com (10.22.229.22) by ORSMSX608.amr.corp.intel.com (10.22.229.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.4; Thu, 24 Jun 2021 01:43:51 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx609.amr.corp.intel.com (10.22.229.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.4 via Frontend Transport; Thu, 24 Jun 2021 01:43:51 -0700 Received: from NAM04-MW2-obe.outbound.protection.outlook.com (104.47.73.171) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2242.4; Thu, 24 Jun 2021 01:43:51 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mfXettZbRreNcbZBw3ObDPK9LAQzaOFQG+1le2VdDAWE69/wCAAgeB0FfmCAv64R97U57m8jEo6zywm/1FNWr0bXLuzbetXwvZEnwqKd4ojuqS/KTGa7cJyqNdExXAdpxhE1neDYbv+OrYtZnBYucT0MkxTbrmMZbm2KfiL7M2RYB2oYRIJZB/SuKTs9m8wQPLUXldJ15Hp3VtdYk2AOQ6w6BOZeO1NypBuc7jPmWma3zFAXg8fcZFR62SflXhLG0iKeGWkr324HdbsVaE471ao0nAA1hE34OFDGDP5bdzBNcOtOXxBVZz9d2CbeHpNGt59A1TJKZ9qlAJnfY5Xv3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/9CTNpg/tp6Mpw4A6zkmv688NudUIEWRpvq1P1qrI/w=; b=YZQcxq2sB/pH+KZrq8osxOqvYUpDOsTqaCGIuvjnLn8Fmhq/a5mzhWaAj0wvJMT7C+mQlhDx8rPC5B4n82YWL9FoxT+51darobuBx3w00EeNZtPeIziRdWrAl2oYnQr1iUiidqLwWn2BxBOjqS+FVwac0v/wClokiBBL8YG0vBPZqnwIqO6pwelX/P/011b/LPNdeqqtBfn0DgoIAKCp+SBPg6NksY334Tc5ieLxMzDoOHrJLokipCO4kVMRT7JA20gNDaZ1SJkTTA8t9FgLgJOOsgP7AGIXRThu/lWX2j+UtmUXce07sw1QRWQB43NAZjdSVosHizBin+qUhjaCpQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/9CTNpg/tp6Mpw4A6zkmv688NudUIEWRpvq1P1qrI/w=; b=oFCg1ax2Mq7dvWZ3aXG9+BoLgTjw0+73TmVA6ZkTuVSevs3AFtVFLJNiberskncaVLiOREcoqTeIXudEoosJ9JXzcSWg0aWgTaz8UQ7QsB9JqZoAYqDDermc3DfQg8Lxyy5GUr6co1STOrKl7laRy7Q5nBpXGz/KKU2tUJvZB5w= Received: from DM6PR11MB2890.namprd11.prod.outlook.com (2603:10b6:5:63::20) by DM5PR11MB1610.namprd11.prod.outlook.com (2603:10b6:4:4::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4264.18; Thu, 24 Jun 2021 08:43:50 +0000 Received: from DM6PR11MB2890.namprd11.prod.outlook.com ([fe80::6d82:e6a7:a1d7:fc91]) by DM6PR11MB2890.namprd11.prod.outlook.com ([fe80::6d82:e6a7:a1d7:fc91%7]) with mapi id 15.20.4264.020; Thu, 24 Jun 2021 08:43:50 +0000 From: "Iremonger, Bernard" To: "ohilyard@iol.unh.edu" CC: "dev@dpdk.org" , "david.marchand@redhat.com" Thread-Topic: [PATCH v2] flow_classify: fix leaking rules on delete Thread-Index: AQHXaFI8+s2mHYHMtEeynxT2wVKGk6si16Jg Date: Thu, 24 Jun 2021 08:43:50 +0000 Message-ID: References: <20210616195724.366103-1-ohilyard@iol.unh.edu> <20210623170708.43755-1-ohilyard@iol.unh.edu> In-Reply-To: <20210623170708.43755-1-ohilyard@iol.unh.edu> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.5.1.3 authentication-results: iol.unh.edu; dkim=none (message not signed) header.d=none;iol.unh.edu; dmarc=none action=none header.from=intel.com; x-originating-ip: [86.45.108.187] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 3766d4cc-14b5-4db0-a360-08d936ec308b x-ms-traffictypediagnostic: DM5PR11MB1610: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:4125; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: uO7o/kyTTw9QGOkdOqyzJKYrwXh9Z+hKhFySvfepx5zx6rU9lf1/3oVmmzNSN69YtWf+CpHO4azKKjdaErZFhINaDs2x13uq5v/+TB4L0HLwfxXZMU2zWbzNkFezeglS6lOpPI02RgyBG4FXnKkfgoJxvU2PxNjVeVN7OWMYceaW6IcbYmjrFmz/FXukObqIetujmpKAlmbuUc3Li8ZrOMyZPiqBPbTtiHAeSQem43HmCEuJq2/a+ZPx9E8YMTWKwI82cEPxE7uIoADg0+BLEkA/5QRka+wgkm4LO/Uujm/KoyPm2EgYbkpzUoDXH2GCG+2g58iFawGNlTzbj72+1EwtOJrfjR0T1NgZwRPNGMscWDcEyFYlTddyUWd0EmYyqFdvnILCDm9LDWYBikd8xJmmr69QM5cKPXOrbTUHWzFUXfAFZogbGunIo1eVjj0KAimFBxHG+rvVvi3QZFI5K27e4fhKguCPdvrNlbtyLPxymy4Rsp49EJBUAhFE457sobFPQ/EL2Rx67YlOhekb7Al8S9hBLxDq6V5Ak5PZqIy7dm89u3039X6H0slN5J+xv2mqz2LPK/HEV6h9poib2N6+9Pps4EKFf6npFAWpq8o= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR11MB2890.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(376002)(136003)(366004)(39860400002)(346002)(396003)(53546011)(186003)(26005)(6506007)(54906003)(33656002)(122000001)(38100700002)(2906002)(316002)(71200400001)(4326008)(66446008)(64756008)(66556008)(66476007)(55016002)(76116006)(9686003)(8936002)(5660300002)(66946007)(8676002)(83380400001)(7696005)(478600001)(6916009)(52536014)(86362001); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?Cj2PDkLQ8MPcVb6EZpZuQQBhNNV7APX/pFAqo6bHQteVjhsKwNMBVnEaecBV?= =?us-ascii?Q?8Zk4F61Zd7zYCnxVcKiPAdrwdtwSBbgGhjXlirQ2zJteVLQzuS+ka2xePAz2?= =?us-ascii?Q?c/zeI6xcDKWVuGNrgOk1eDZjDnr7XwKbjUQZxNfFCBopVIhzB4MmQVEFDO2P?= =?us-ascii?Q?djkjRWo+4Cm4KpMij6hiQLi1pmqxVm3ILPQQBi2WCu0dQMhfZ6t5bflKQ5UQ?= =?us-ascii?Q?QtVijWckmV4eR3pXFjhtq/X6wrt21x4813h3OB4+A0FY8N/9AHLaDH2knPtG?= =?us-ascii?Q?bxqcgpfEra1PrKuE4DlAnM6SA0UI9cYvM3vMwBB8z9/JpQCXESV8F65RJzOH?= =?us-ascii?Q?ABuKSwks7MhGaHpUN9UsFKnJq1Dhnr0fAAfpAaxReppnNosvpXDpM1RzzuPf?= =?us-ascii?Q?8PmKKdgvrMbphfUUhhoGSqvUBiCDURZ2Y/B+th9tZ8/j6AiVCbjuiWu2wMqN?= =?us-ascii?Q?FmlSYE15hy3RX/7wQztfXzqL+GycB+bZGX/Cqm4WP2TSJQPGNOqZpX4urcGC?= =?us-ascii?Q?+Acz/FRbteKBIAa7ORzFPsltAdV1j+VkfJEj+ELYpBtuo6Ih6+8jPA/Ur+HP?= =?us-ascii?Q?+FeZiMsxBQ1rMQ+oGu0XeX/rXcHFYyS7XBL7+kTYu3E4LpZCgZ5iX1i4BqW0?= =?us-ascii?Q?/pnCBaL7ug6eLTrEGxxH8qIysq9pz5Wv0ZPsLduMNYVTw1itb/cR7tcxjAdY?= =?us-ascii?Q?2UwHBMgIc3NAb6rh/7MuZ35ftpNjZsjnrRl/CB73kBAM2q5WHqmjsWduvyo3?= =?us-ascii?Q?bAX4OreqgvNEr/Hi+Mvdiod3z0MkD0m0Ew4CCH8P3x3nAQd3XGyiXzBlCJ8b?= =?us-ascii?Q?/Y2gWe/b9FtQrbaxjtulpn20F1cpTYFwc3tFydChb8HJjscZjhKAKZ1KGPEk?= =?us-ascii?Q?dOyGQCSlSzVE7IKJPEuHkC2JP2IAxcuhgQK8cArzSkLFabhp47+ga+SI+USj?= =?us-ascii?Q?4XT/D18Qn8jKFm2pBrP0+4v+DSvnSJrgmb59cRbfBAXrcFq/tfgece7qhHf/?= =?us-ascii?Q?I3g3aQO0jTZ49zbRO/NgWpjjJ627ach/I2x6NJRd15FjGGR9ohsCat/b1n+F?= =?us-ascii?Q?Hk2ylISSshFjOv8qPSgAD2f3Mf77Sk13eZBbUvHKZ5zI4OGCBBiBjyvBM+RG?= =?us-ascii?Q?tG6zbYWSXaqFg0SjTiC2AJ86lfv2wTyUOLjvkHVEnVU5aTJQMIvx7m4yFNyz?= =?us-ascii?Q?fP82C0cc491CGHDzb6oEmK/Rw2VsnDvkIzshwl+jaKepSXgIkZI9Bk2KznXz?= =?us-ascii?Q?OPtnZyBFKS8Llqo5JOtEQtqZifslm8Fn51Q1CV4+JF/8f9IQEGxoXfsS/X0t?= =?us-ascii?Q?7eajaQ2raYp9gPxiEKm3sULb?= x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR11MB2890.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3766d4cc-14b5-4db0-a360-08d936ec308b X-MS-Exchange-CrossTenant-originalarrivaltime: 24 Jun 2021 08:43:50.2896 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: /rdj/n24c8EIXtvfu1hWUAe1macme37oT6EpIfHZZ71ctfvBeJVuXlTYmGD2PM+UR8IK+IQwDBAEZa54BwvbPxAyn3WZQoxrBv0KixAfCMA= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR11MB1610 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH v2] flow_classify: fix leaking rules on delete X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 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" Hi Owen, > -----Original Message----- > From: ohilyard@iol.unh.edu > Sent: Wednesday, June 23, 2021 6:07 PM > To: Iremonger, Bernard > Cc: dev@dpdk.org; david.marchand@redhat.com; Owen Hilyard > > Subject: [PATCH v2] flow_classify: fix leaking rules on delete >=20 > From: Owen Hilyard >=20 > Rules in a classify table were not freed if the table had a delete functi= on. >=20 > Fixes: be41ac2a3 ("flow_classify: introduce flow classify library") >=20 > Signed-off-by: Owen Hilyard > --- > lib/flow_classify/rte_flow_classify.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/lib/flow_classify/rte_flow_classify.c > b/lib/flow_classify/rte_flow_classify.c > index f125267e8..d3ba2ed22 100644 > --- a/lib/flow_classify/rte_flow_classify.c > +++ b/lib/flow_classify/rte_flow_classify.c > @@ -579,12 +579,12 @@ rte_flow_classify_table_entry_delete(struct > rte_flow_classifier *cls, > &rule->u.key.key_del, > &rule->key_found, > &rule->entry); > - > + if (ret =3D=3D 0) > + free(rule); > return ret; > } > } > } > - free(rule); > return ret; > } >=20 > -- > 2.30.2 This patch should be backported. Please add the following line after the Fixes line: Cc: stable@dpdk.org Otherwise=20 Acked-by: Bernard Iremonger