From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36822) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zq1Mm-0002vb-34 for qemu-devel@nongnu.org; Sat, 24 Oct 2015 12:08:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zq1Mi-0003C1-3T for qemu-devel@nongnu.org; Sat, 24 Oct 2015 12:08:24 -0400 Received: from mga09.intel.com ([134.134.136.24]:30836) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zq1Mh-0003Bx-Ty for qemu-devel@nongnu.org; Sat, 24 Oct 2015 12:08:20 -0400 Message-ID: <562BACE8.8070507@intel.com> Date: Sun, 25 Oct 2015 00:08:08 +0800 From: "Lan, Tianyu" MIME-Version: 1.0 References: <1445445464-5056-1-git-send-email-tianyu.lan@intel.com> <1445445464-5056-9-git-send-email-tianyu.lan@intel.com> <20151022155650-mutt-send-email-mst@redhat.com> In-Reply-To: <20151022155650-mutt-send-email-mst@redhat.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC Patch 08/12] IXGBEVF: Rework code of finding the end transmit desc of package List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: shannon.nelson@intel.com, emil.s.tantilov@intel.com, kvm@vger.kernel.org, linux-pci@vger.kernel.org, donald.c.skidmore@intel.com, mitch.a.williams@intel.com, eddie.dong@intel.com, agraf@suse.de, qemu-devel@nongnu.org, yang.z.zhang@intel.com, nrupal.jani@intel.com, john.ronciak@intel.com, intel-wired-lan@lists.osuosl.org, jeffrey.t.kirsher@intel.com, jesse.brandeburg@intel.com, bhelgaas@google.com, pbonzini@redhat.com, carolyn.wyborny@intel.com, matthew.vick@intel.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org On 10/22/2015 8:58 PM, Michael S. Tsirkin wrote: > Do you really need to play the shifting games? > Can't you just reset everything and re-initialize the rings? > It's slower but way less intrusive. > Also removes the need to track writes into rings. Shift ring is to avoid losing those packets in the ring. This may cause some race condition and so I introduced a lock to prevent such cases in the latter patch. Yes, reset everything after migration can make thing easy. But just like you said it would affect performance and loss more packets. I can do a test later to get data about these two way.