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 3AC0A45682 for ; Mon, 22 Jul 2024 14:40:07 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2F290402DA; Mon, 22 Jul 2024 14:40:07 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.11]) by mails.dpdk.org (Postfix) with ESMTP id 5F120400D7; Mon, 22 Jul 2024 14:40:04 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1721652004; x=1753188004; h=message-id:date:subject:to:cc:references:from: in-reply-to:content-transfer-encoding:mime-version; bh=SarAm5/BJlbuga0flPporZqaiRid+qOPIjHaXPSYpwc=; b=JUH5dH3jJXhxgKV36Kzt2AZTtMKS8U+sAFk55mNUnRGD09HsH/1mbImA 1WO6U1BiEfBP1FNoP3698mU6VM9cE1Q49FK5ejAu7QJMl6pdtPtuMBs3p uD9NmfO6J0gHGDhLkVUQYTFICXH7zVELxMjF8tYby4ZTt+RbGFP2IBo2+ 9pPynLlkJeryAmwzzx+RIgu3aTGheZXOR6lPVDv/yb7vgYq/vtVTzirSy agiDC04eDM9+aV4WzSmox6WYqoKASHsMLl27BbHHXQASZXAVG6Kr89+HX TGm5y7rMjQkqFCPXXvv2wRo0FTKhUPXnfHjAncGO7gAZJ7R9qAcknr8nH g==; X-CSE-ConnectionGUID: 7YccZZiQR6qw9T8uUP7PDA== X-CSE-MsgGUID: nznuGbAqSzy2cTlOyXnhFg== X-IronPort-AV: E=McAfee;i="6700,10204,11140"; a="29802616" X-IronPort-AV: E=Sophos;i="6.09,228,1716274800"; d="scan'208";a="29802616" Received: from fmviesa004.fm.intel.com ([10.60.135.144]) by orvoesa103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jul 2024 05:40:03 -0700 X-CSE-ConnectionGUID: C3uxbxILRDCckZT4ZUrOFg== X-CSE-MsgGUID: yRAti9w6Q5WyCrjQhZfllQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.09,228,1716274800"; d="scan'208";a="56434413" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by fmviesa004.fm.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 22 Jul 2024 05:40:03 -0700 Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Mon, 22 Jul 2024 05:40:02 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39 via Frontend Transport; Mon, 22 Jul 2024 05:40:02 -0700 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.176) 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.2507.39; Mon, 22 Jul 2024 05:40:02 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=xHmWYVXx19dYcj0dFeW/y01sXyIQHLVh6q2St/p7qHVFHSykv6CThLeyEiU0+T1Nsz8LRbmDewEVfavOCauiYrNCh/WTj/atZckXIk47mVzf7UIQNgFz/z3KmCGtFZ7MvT0hi6cQhXo+ZIxWUY3+8uiJSGlECC3YP10QJcgIX9q+bO/Nl7rJhZi+TRY/C3DW5Oz6dU60gQfigkIWiddTp7ig20SaojOx48KX1zh+Jft3pi6BpFww27CavgoM3phPnzpDRV2nSo23rpX8cc32JYa8VT73zJ0zoD4ZbaHlnUfioF+V4M/LrUXAZdFszlHY5JDU9iIsh8nAjDIsp74YiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=RYEDHVfsn3r4wPC8gCAp8iKZYsEVgMbVmhCzKTmRFZE=; b=iK28SgpF5eAgx1Oo5eZMtR+3MmBvNgi4K48LTNuZq/ogbaUQiib4m78hYXCy1QrBJpZwXbRv2sYYQsSTucXFWocnNJ37lkjAl8/1ub9dDTLK57NDDShVMEPu8mQNVlXwwQDlZZI0UAgnvxlNCS72Bt1i9NPSlI0pB/nxbGgX4j7DpWCHxEcNYmTkK7UTBNosRRanVbg42ofYEWiwHbeDlWRK7moEY0hJpUR+C5GnfTJ5m09yTJw7wZ+AM9r3WjyTy4XdMmN34ubGMlOuFdeccUqdCiW1FHOp1lykqYmyYAed4vhHQPkfbHdxdbI6fUvGTFDbjCcbXPL+2M5SYz0bRw== 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 Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from DM4PR11MB6502.namprd11.prod.outlook.com (2603:10b6:8:89::7) by DM6PR11MB4642.namprd11.prod.outlook.com (2603:10b6:5:2a2::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7784.14; Mon, 22 Jul 2024 12:39:54 +0000 Received: from DM4PR11MB6502.namprd11.prod.outlook.com ([fe80::21e4:2d98:c498:2d7a]) by DM4PR11MB6502.namprd11.prod.outlook.com ([fe80::21e4:2d98:c498:2d7a%7]) with mapi id 15.20.7762.027; Mon, 22 Jul 2024 12:39:54 +0000 Message-ID: <79ce202e-38da-4da4-8754-726d8a12f976@intel.com> Date: Mon, 22 Jul 2024 14:39:46 +0200 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] net/vdev: fix insert vdev core dump To: Mingjin Ye , CC: References: <20240314093630.1066948-4-mingjinx.ye@intel.com> <20240716095328.1820597-1-mingjinx.ye@intel.com> Content-Language: en-US From: "Burakov, Anatoly" In-Reply-To: <20240716095328.1820597-1-mingjinx.ye@intel.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: PA7P264CA0120.FRAP264.PROD.OUTLOOK.COM (2603:10a6:102:34c::18) To DM4PR11MB6502.namprd11.prod.outlook.com (2603:10b6:8:89::7) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM4PR11MB6502:EE_|DM6PR11MB4642:EE_ X-MS-Office365-Filtering-Correlation-Id: ab14fe40-4893-477c-d451-08dcaa4b634c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|376014; X-Microsoft-Antispam-Message-Info: =?utf-8?B?NzFUOHBUMWRpQ1c3OTZTT0xmWTBLS2ROWHRsaXBuTkZxd1VwVVBLN3IwR2pz?= =?utf-8?B?OTB4eFdxV3BlOURSb3o3YVpvS2lzc3N6UWZLb2gwV1IyUEh0bE9DRjlVUUxp?= =?utf-8?B?M1BoV0s5SC9zQWw1cWNRSng2OWpKbVdoYS9wMmIxMU9XK3Vmcm9Fa21RcUlX?= =?utf-8?B?YytWU0dmWHZuY2lkUVZZcnJnZEhPWDdJTUt3cXJlbnczc1c1ZFpYSCtTaGcv?= =?utf-8?B?elRMaEhlaERIdTQ0N3VQd0FQVU45dUpmZWVpdzhnS0gxOXpDZllWbHJYdDJu?= =?utf-8?B?ODMrTEtnWVYrOEd3UFpGeTF4Um9BRlFRL0pPZmRQY1lTS0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Zld0OXU3ajdsWGI4bWRkUGFWSWdudlhRMjQwSFpz?= =?utf-8?B?RHgvVnFMcEZQL3cweWJGU1BLdHpEdlkyMHJ3WnA1MWc1czgxNmt0bmxrZmM2?= =?utf-8?B?dkhnaVgvTG1vcHBiRVMrUVUvY0loY05MYUtaQTVhWU9vME1wQXk1Nk5EZmQ4?= =?utf-8?B?M0FkeE80UEp6TXpyNEs5ZEJlTHhSRVRCMENXMmJtdGlzU1BhTTdZZzEwalZM?= =?utf-8?B?a1M3Ky92enVjQ1kxekI4aUFYVUI2STk0RnVzeHBnYzBXT0JRcXBUT0E4ank1?= =?utf-8?B?UGJrbXllSWlHb3l6c1VUUWZTazlHT3N0UWxzYTh4c3ZlT0V2aE5RVHJNc1hS?= =?utf-8?B?YWlLNEppKzI3REdaam9vaVQyblhpMDhoelg0SUtvMDFvSy9ZN21ST2wrL3Uz?= =?utf-8?B?Z2Z4Rk5ZbTh0YVYyU21LbGpaWW1LS1o5Z0x5S3lvNlBWd2N4dFBlaGRhNDMv?= =?utf-8?B?aHdOZWhMb1dqMXV4aUtCcVZJWGRJMm9HZmN5QS9mU09ndG1VbnBOWFlpekxt?= =?utf-8?B?eXRXZm01aXJ0azhXUklId2RtV013cktQOEJpZTJUUUk2RStzbUNtMEFsektt?= =?utf-8?B?UllBQ1FkZytiWGpQWWY1Zz09?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM4PR11MB6502.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(1800799024)(366016)(376014); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?NnJKOW13NjRiaW1FaWJSUDFxZEVZcENFTDZRRUhYRjEvQjhlTkFySXluRUlr?= =?utf-8?B?T0lYYklyUEQxdWhhQWFnVUpSOS92aTdYY01RN2tweXZZaVhENXVuY08xVTc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5kd0gydkxwdlJZd25RZVNWUG5nYlBHcCtFVTZLaG9Gc3NyS29xMHBN?= =?utf-8?B?UlBQQ2RIUGNGMzhMYTlXeC9pSjdjSTZCeGV1RStySEkrNFA3RXNnZVlFQ0xY?= =?utf-8?B?UlZtVHdRUDUycVdDcDIzYWNteEgvdkFZaWJmTUxWbjFaU1V2SW9RSCtVV2hi?= =?utf-8?B?ZEdvVzJrSzBvVmRmV3V6bnN3enRYWUt2S1QzSzhER1pxZmxxSkNCOEtDNDZQ?= =?utf-8?B?N25FWk9iaUtFb2RHem83NnZKWjBaY3pZN0xtb0twa0l5MVlMaHp5TmhRTHFI?= =?utf-8?B?Y0E9PQ==?= X-MS-Exchange-CrossTenant-Network-Message-Id: ab14fe40-4893-477c-d451-08dcaa4b634c X-MS-Exchange-CrossTenant-AuthSource: DM4PR11MB6502.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Jul 2024 12:39:54.6178 (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: DA7pGDj0l9zyzJ4Kr//EFtCCrkG6Hzq6UyLTlfP2rbEBaimpDuYssLfrSe8VMTtMGub8NRCsyHFVF8hQ0FOJMwRR4CUbQseIDxpMCfv7tSQ= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB4642 X-OriginatorOrg: intel.com X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On 7/16/2024 11:53 AM, Mingjin Ye wrote: > In secondary processes, insert_vdev() may be called multiple times on the > same device due to multi-process hot-plugging of the vdev bus and EAL > parameters to add the same vdev. > > In this case, when rte_devargs_insert() is called, the devargs->name > reference will be invalidated because rte_devargs_insert() destroys the > just-allocated devargs and replaces the pointer from the devargs list. > As a result, the reference to devargs->name stored in dev->device.name > will be invalid. > > This patch fixes the issue by setting the device name after calling > rte_devargs_insert(). > > Fixes: cdb068f031c6 ("bus/vdev: scan by multi-process channel") > Cc: stable@dpdk.org > > Signed-off-by: Mingjin Ye > --- > v2: Modify commit log. > --- Forgot to add my review tag: Reviewed-by: Anatoly Burakov -- Thanks, Anatoly