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 B48DAA0547; Mon, 21 Jun 2021 05:27:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2A9A640040; Mon, 21 Jun 2021 05:27:53 +0200 (CEST) Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by mails.dpdk.org (Postfix) with ESMTP id 9237E4003F for ; Mon, 21 Jun 2021 05:27:51 +0200 (CEST) Received: from dggemv703-chm.china.huawei.com (unknown [172.30.72.54]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4G7ZdZ06csz72HF for ; Mon, 21 Jun 2021 11:24:34 +0800 (CST) Received: from dggema774-chm.china.huawei.com (10.1.198.216) by dggemv703-chm.china.huawei.com (10.3.19.46) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2176.2; Mon, 21 Jun 2021 11:27:47 +0800 Received: from dggpemm500008.china.huawei.com (7.185.36.136) by dggema774-chm.china.huawei.com (10.1.198.216) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Mon, 21 Jun 2021 11:27:46 +0800 Received: from dggpemm500008.china.huawei.com ([7.185.36.136]) by dggpemm500008.china.huawei.com ([7.185.36.136]) with mapi id 15.01.2176.012; Mon, 21 Jun 2021 11:27:46 +0800 From: wangyunjian To: Ferruh Yigit , "dev@dpdk.org" CC: "liucheng (J)" , dingxiaoxiong Thread-Topic: [dpdk-dev] [PATCH] kni: fix wrong mbuf alloc count in kni_allocate_mbufs Thread-Index: AQHXVhXNvHD3rHQOKE6z2tg3+SVz/qsZW8sAgASR15A= Date: Mon, 21 Jun 2021 03:27:46 +0000 Message-ID: <50aabf5f062c4858806bf6429a1a8c24@huawei.com> References: <4ebfe0d38b335a437edc9c58368153d005f562ce.1622460655.git.wangyunjian@huawei.com> <0d996824-6015-18d6-c730-1821a34aae0c@intel.com> In-Reply-To: <0d996824-6015-18d6-c730-1821a34aae0c@intel.com> Accept-Language: zh-CN, en-US Content-Language: zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.174.243.60] Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-CFilter-Loop: Reflected Subject: Re: [dpdk-dev] [PATCH] kni: fix wrong mbuf alloc count in kni_allocate_mbufs 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" PiAtLS0tLU9yaWdpbmFsIE1lc3NhZ2UtLS0tLQ0KPiBGcm9tOiBGZXJydWggWWlnaXQgW21haWx0 bzpmZXJydWgueWlnaXRAaW50ZWwuY29tXQ0KPiBTZW50OiBGcmlkYXksIEp1bmUgMTgsIDIwMjEg OTozNyBQTQ0KPiBUbzogd2FuZ3l1bmppYW4gPHdhbmd5dW5qaWFuQGh1YXdlaS5jb20+OyBkZXZA ZHBkay5vcmcNCj4gQ2M6IGxpdWNoZW5nIChKKSA8bGl1Y2hlbmcxMUBodWF3ZWkuY29tPjsgZGlu Z3hpYW94aW9uZw0KPiA8ZGluZ3hpYW94aW9uZ0BodWF3ZWkuY29tPg0KPiBTdWJqZWN0OiBSZTog W2RwZGstZGV2XSBbUEFUQ0hdIGtuaTogZml4IHdyb25nIG1idWYgYWxsb2MgY291bnQgaW4NCj4g a25pX2FsbG9jYXRlX21idWZzDQo+IA0KPiBPbiA1LzMxLzIwMjEgMTowOSBQTSwgd2FuZ3l1bmpp YW4gd3JvdGU6DQo+ID4gRnJvbTogWXVuamlhbiBXYW5nIDx3YW5neXVuamlhbkBodWF3ZWkuY29t Pg0KPiA+DQo+ID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