From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id CFC05A04FE; Wed, 15 Jan 2020 08:07:57 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 457131C068; Wed, 15 Jan 2020 08:07:57 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id 345011BFFE; Wed, 15 Jan 2020 08:07:55 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Jan 2020 23:07:54 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,321,1574150400"; d="scan'208";a="225476041" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by orsmga003.jf.intel.com with ESMTP; 14 Jan 2020 23:07:53 -0800 Received: from fmsmsx155.amr.corp.intel.com (10.18.116.71) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 14 Jan 2020 23:07:53 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX155.amr.corp.intel.com (10.18.116.71) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 14 Jan 2020 23:07:53 -0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.245]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.55]) with mapi id 14.03.0439.000; Wed, 15 Jan 2020 15:05:16 +0800 From: "Liu, Yong" To: "eperezma@redhat.com" , "bugzilla@dpdk.org" , "dev@dpdk.org" , Maxime Coquelin CC: Jason Wang , "Michael S. Tsirkin" , Adrian Moreno Zapata Thread-Topic: [dpdk-dev] [Bug 383] dpdk virtio_user lack of notifications make vhost_net+napi stops tx buffers Thread-Index: AQHVxwQOVJzitC1ynk6CQ827O1PLaqfh9lOAgAlYYCA= Date: Wed, 15 Jan 2020 07:05:16 +0000 Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E63481417@SHSMSX103.ccr.corp.intel.com> References: <6d0d5484704aa5cc79f20ac94ac6103e430f712f.camel@redhat.com> In-Reply-To: <6d0d5484704aa5cc79f20ac94ac6103e430f712f.camel@redhat.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZTBjZWViNjAtODk2ZC00ZWE4LWFmM2EtYjFhNGYxZWEwNjFlIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoidktqTkhCV3ZEa0tZcWlkUkRFM1ZlQUJNRncwb2dSSThLVDVBQzdGeFwvSUpBNkRXTEZZeCtvTGlSZmhvUHR5YmkifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 Subject: Re: [dpdk-dev] [Bug 383] dpdk virtio_user lack of notifications make vhost_net+napi stops tx buffers 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" DQoNCj4gLS0tLS1PcmlnaW5hbCBNZXNz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