From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id BD0781BE0 for ; Thu, 8 Nov 2018 12:25:21 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 08 Nov 2018 03:25:20 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,478,1534834800"; d="scan'208";a="279383743" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga006.fm.intel.com with ESMTP; 08 Nov 2018 03:25:20 -0800 Received: from fmsmsx123.amr.corp.intel.com (10.18.125.38) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 8 Nov 2018 03:25:20 -0800 Received: from hasmsx106.ger.corp.intel.com (10.184.198.20) by fmsmsx123.amr.corp.intel.com (10.18.125.38) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 8 Nov 2018 03:25:20 -0800 Received: from hasmsx105.ger.corp.intel.com ([169.254.1.193]) by HASMSX106.ger.corp.intel.com ([169.254.10.88]) with mapi id 14.03.0415.000; Thu, 8 Nov 2018 13:25:17 +0200 From: "Stojaczyk, Dariusz" To: Thomas Monjalon , "dev@dpdk.org" CC: "gaetan.rivet@6wind.com" , "Zhang, Qi Z" , "Guo, Jia" Thread-Topic: [PATCH] devargs: do not replace already inserted devargs Thread-Index: AQHUdvCbSithoLnKnECKIBOzRfCUu6VFvPAw Date: Thu, 8 Nov 2018 11:25:17 +0000 Message-ID: References: <20181107232105.19187-1-thomas@monjalon.net> In-Reply-To: <20181107232105.19187-1-thomas@monjalon.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZTE1MWViYjEtNDFhOC00NWI5LWJiYWYtYzNkOGVhMWYwNjI3IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiNFN5SWVHVllWbklFM01rK1VnVThWWVVuMlFIUG9aYnRKMXJoRENodUFneHZLeEdrMEp3OFVKeERxOEZ6ME5tSiJ9 x-ctpclassification: CTP_NT x-originating-ip: [10.102.11.35] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] devargs: do not replace already inserted devargs 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, 08 Nov 2018 11:25:22 -0000 > -----Original Message----- > From: Thomas Monjalon [mailto:thomas@monjalon.net] > Sent: Thursday, November 8, 2018 12:21 AM > To: dev@dpdk.org > Cc: gaetan.rivet@6wind.com; Zhang, Qi Z ; Guo, Jia > ; Stojaczyk, Dariusz > Subject: [PATCH] devargs: do not replace already inserted devargs >=20 > The devargs of a device can be replaced by a newly allocated one > when trying to probe again the same device (multi-process or > multi-ports scenarios). This is breaking some pointer references. >=20 > It can be avoided by copying the new content, freeing the new devargs, > and returning the already inserted pointer. >=20 > Signed-off-by: Thomas Monjalon > --- Tested-by: Darek Stojaczyk