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 7D579A0505 for ; Tue, 29 Mar 2022 04:14:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6EC2942857; Tue, 29 Mar 2022 04:14:53 +0200 (CEST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id 596F040691; Tue, 29 Mar 2022 04:14:49 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1648520089; x=1680056089; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=gTDgj2qRaustCpw5BxQeajVNi6zhuXXB6E61jitLOws=; b=HYWuft+sfNaWGexJXf04xf2G1I8kCh52PJzVk5kDRd/wObizpCHyZgVd XcafYaK05pRvwmgJotlApHbEghKKuDkNmbDqtNqhsej0PgWUF/+LrWqFk 9Q7qbvCZAThgfiiQ8T++vuIU3Q7h21it8qgz24Z6cmM0J0IYo2N4jlHZD ND51lV2Smzg0kzHfJI9G6I4R/aoc6Fbe1MvT8oCiBoyQ7Bq/cQ4bzkR49 gMSXVr9vZubMP9Hc3sFS0exiRVnTuFNlSi4G4mGljHoX0DGx0pD5onP5V Y81Dv9x4AytxUlNGNFDOhBQXfj9EG1PKJ5nVOJyAkPKmX2A2CKXEITNNO A==; X-IronPort-AV: E=McAfee;i="6200,9189,10300"; a="319842812" X-IronPort-AV: E=Sophos;i="5.90,219,1643702400"; d="scan'208";a="319842812" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Mar 2022 19:14:48 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,219,1643702400"; d="scan'208";a="585404747" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by orsmga001.jf.intel.com with ESMTP; 28 Mar 2022 19:14:47 -0700 Received: from shsmsx606.ccr.corp.intel.com (10.109.6.216) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Mon, 28 Mar 2022 19:14:47 -0700 Received: from shsmsx601.ccr.corp.intel.com (10.109.6.141) by SHSMSX606.ccr.corp.intel.com (10.109.6.216) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Tue, 29 Mar 2022 10:14:45 +0800 Received: from shsmsx601.ccr.corp.intel.com ([10.109.6.141]) by SHSMSX601.ccr.corp.intel.com ([10.109.6.141]) with mapi id 15.01.2308.027; Tue, 29 Mar 2022 10:14:44 +0800 From: "Zhang, Qi Z" To: "Huang, Wei" , "dev@dpdk.org" , "thomas@monjalon.net" , "Xu, Rosen" , "nipun.gupta@nxp.com" , "hemant.agrawal@nxp.com" CC: "stable@dpdk.org" , "Zhang, Tianfei" , "Yigit, Ferruh" Subject: RE: [PATCH v3] raw/ifpga: remove vdev when ifpga is closed Thread-Topic: [PATCH v3] raw/ifpga: remove vdev when ifpga is closed Thread-Index: AQHYOqa77Toxgx0PvESIQgYdgKi4LazVJNMAgACKoVA= Date: Tue, 29 Mar 2022 02:14:44 +0000 Message-ID: <687b7f7a191846c39e12a08c0e0f27ce@intel.com> References: <20220315011755.1588005-1-wei.huang@intel.com> <20220318085755.2134030-1-wei.huang@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.6.401.20 dlp-product: dlpe-windows x-originating-ip: [10.239.127.36] Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 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 DQo+IC0tLS0tT3JpZ2luYWwgTWVzc2FnZS0tLS0tDQo+IEZyb206IEh1YW5nLCBXZWkgPHdlaS5o dWFuZ0BpbnRlbC5jb20+DQo+IFNlbnQ6IFR1ZXNkYXksIE1hcmNoIDI5LCAyMDIyIDk6NTYgQU0N Cj4gVG86IGRldkBkcGRrLm9yZzsgdGhvbWFzQG1vbmphbG9uLm5ldDsgWHUsIFJvc2VuDQo+IDxy b3Nlbi54dUBpbnRlbC5jb20+OyBuaXB1bi5ndXB0YUBueHAuY29tOyBoZW1hbnQuYWdyYXdhbEBu eHAuY29tDQo+IENjOiBzdGFibGVAZHBkay5vcmc7IFpoYW5nLCBUaWFuZmVpIDx0aWFuZmVpLnpo YW5nQGludGVsLmNvbT47IFpoYW5nLCBRaSBaDQo+IDxxaS56LnpoYW5nQGludGVsLmNvbT47IFlp Z2l0LCBGZXJydWggPGZlcnJ1aC55aWdpdEBpbnRlbC5jb20+DQo+IFN1YmplY3Q6IFJFOiBbUEFU Q0ggdjNdIHJhdy9pZnBnYTogcmVtb3ZlIHZkZXYgd2hlbiBpZnBnYSBpcyBjbG9zZWQNCj4gDQo+ IEhpIFRob21hcywNCj4gDQo+IFdvdWxkIHlvdSBwbGVhc2UgY2hlY2sgdGhpcyBwYXRjaCBpcyBh Y2NlcHRhYmxlID8NCg0KSGkgV2VpOg0KCTIyLjA3IGN5Y2xlIGp1c3QgYmVnaW5zLCBJdCBtYXkg bm90IG5lY2Vzc2FyeSB0byBwdXNoIFBNRCBtZXJnZSBxdWl0ZSBlYXJseSDwn5iKDQoJQmVsb3cg aXMgdGhlIHJvYWRtYXAgZm9yIHlvdXIgcmVmZXJlbmNlDQoNCmh0dHA6Ly9jb3JlLmRwZGsub3Jn L3JvYWRtYXAvDQoNClByb3Bvc2FsIGRlY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